Skip to content

Commit

Permalink
binder: Fix expected result of security test
Browse files Browse the repository at this point in the history
The test name includes "fails" but it asserts the result is OK. The test
was added in #9428.

The binder tests are passing on the Android CI, but for some reason the
tests with sdk >= 29 are skipped. Robolectric 4.8 claims API level 32
support and the tests are skipped even when using Java 11 and 17.
  • Loading branch information
ejona86 committed Sep 9, 2022
1 parent 074e919 commit 24287b0
Showing 1 changed file with 1 addition and 1 deletion.
Expand Up @@ -460,7 +460,7 @@ public void testIsProfileOwnerOnOrgOwned_failsForProfileOwnerOnNonOrgOwned() thr

policy = SecurityPolicies.isProfileOwnerOnOrganizationOwnedDevice(appContext);

assertThat(policy.checkAuthorization(OTHER_UID).getCode()).isEqualTo(Status.OK.getCode());
assertThat(policy.checkAuthorization(OTHER_UID).getCode()).isEqualTo(Status.PERMISSION_DENIED.getCode());
}

@Test
Expand Down

0 comments on commit 24287b0

Please sign in to comment.