
org.robolectric.shadows.ShadowProcess Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of framework Show documentation
Show all versions of framework Show documentation
An alternative Android testing framework.
The newest version!
package org.robolectric.shadows;
import org.robolectric.annotation.Implementation;
import org.robolectric.annotation.Implements;
import org.robolectric.annotation.Resetter;
@Implements(android.os.Process.class)
public class ShadowProcess {
private static int pid;
@Implementation
public static final int myPid() {
return pid;
}
public static void setPid(int pid) {
ShadowProcess.pid = pid;
}
@Resetter
public static void reset() {
ShadowProcess.pid = 0;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy