You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[ x] I have verified there are no duplicate active or recent bugs, questions, or requests.
[ x] I have verified that I am using the latest version of PiracyChecker.
[ x] I have given my issue a non-generic title.
[ x] I have read over the documentation (before asking questions on how to do something).
Details
PiracyChecker version: 1.2.3
Device OS version: emulator
Device Manufacturer: N/A
Device Name: Nexus 5
Reproduction Steps
As says UnauthorizedAppTest:
/**
Specific test cases for unauthorized apps. Requires to install an unauthorized app before running this tests.
*/
install apk for unauthorized app (i.e. Lucky patch 7.4.2)
Run test
Test fails with message "PiracyChecker FAILED : PiracyCheckError is not At least one pirate app has been detected and the app must be reinstalled when all unauthorized apps are uninstalled.."
Possible Solution :
@Test
public void verifyUnauthorizedApps_DONTALLOW() throws Throwable {
final CountDownLatch signal = new CountDownLatch(1);
uiThreadTestRule.runOnUiThread(new Runnable() {
@Override
public void run() {
new PiracyChecker(InstrumentationRegistry.getTargetContext())
.enableUnauthorizedAppsCheck(true)
.blockIfUnauthorizedAppUninstalled("piracychecker_preferences", "app_unauthorized")
.callback(new PiracyCheckerCallback() {
@Override
public void allow() {
assertTrue("PiracyChecker FAILED: There is an unauthorized app installed.", false);
signal.countDown();
}
@Override
public void dontAllow(@NonNull PiracyCheckerError error, @Nullable PirateApp app) {
if (error == PiracyCheckerError.PIRATE_APP_INSTALLED
|| error == PiracyCheckerError.BLOCK_PIRATE_APP) {
...
so add || error == PiracyCheckerError.BLOCK_PIRATE_APP.
NB : same probably holds true for verifyUnauthorizedCustomApp_DONTALLOW test method, but that test doesn't fail.
The text was updated successfully, but these errors were encountered:
GerritDeMeulder
changed the title
AndroidTest 2. UnauthorizedAppTest: Fails due to PiracyCheckerError.PIRATE_APP_INSTALLED but BLOCK_PIRATE_APP
AndroidTest UnauthorizedAppTest: Fails due to PiracyCheckerError enum return value not PIRATE_APP_INSTALLED but BLOCK_PIRATE_APP.
Sep 20, 2018
Details
1.2.3
emulator
N/A
Nexus 5
Reproduction Steps
As says UnauthorizedAppTest:
/**
*/
Possible Solution :
so add || error == PiracyCheckerError.BLOCK_PIRATE_APP.
NB : same probably holds true for verifyUnauthorizedCustomApp_DONTALLOW test method, but that test doesn't fail.
The text was updated successfully, but these errors were encountered: