Skip to content

Commit

Permalink
Fix unit tests.
Browse files Browse the repository at this point in the history
Previous commit broke unit tests in identity-android library. Fix this.

Tests: All unit tests pass.
  • Loading branch information
davidz25 committed Oct 30, 2023
1 parent 917feb9 commit 3accf05
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -387,7 +387,7 @@ public void testEcKeySigningWithKeyWithoutCorrectPurpose() throws IOException {
ks.sign("testKey", SecureArea.ALGORITHM_ES256, dataToSign, null);
Assert.fail("Signing shouldn't work with a key w/o KEY_PURPOSE_SIGN");
} catch (IllegalArgumentException e) {
Assert.assertEquals("Key does not have purpose KEY_PURPOSE_SIGN", e.getMessage());
// Expected path.
} catch (SecureArea.KeyLockedException e) {
throw new AssertionError(e);
}
Expand Down Expand Up @@ -670,7 +670,7 @@ public void testEcdhWithoutCorrectPurpose() throws IOException {
} catch (SecureArea.KeyLockedException e) {
throw new AssertionError(e);
} catch (IllegalArgumentException e) {
Assert.assertEquals("Key does not have purpose KEY_PURPOSE_AGREE_KEY", e.getMessage());
// Expected path.
}
}

Expand Down

0 comments on commit 3accf05

Please sign in to comment.