Test tweaks, expecting the correct error

This commit is contained in:
Dave
2015-06-29 22:27:54 +02:00
parent 7f641d31e3
commit 59b2be78c1
3 changed files with 18 additions and 21 deletions

View File

@@ -100,14 +100,14 @@ public class NoUserTest {
try {
NoUser.createUserFromFile(null, "password".toCharArray());
fail("Should have thrown a NullPointerException.");
} catch (NullPointerException e) {
fail("Should have thrown a IllegalArgumentException.");
} catch (IllegalArgumentException e) {
// Do nothing, correct
}
try {
NoUser.createUserFromFile(null, null);
fail("Should have thrown a NullPointerException.");
fail("Should have thrown a IllegalArgumentException.");
} catch (NullPointerException e) {
// Do nothing, correct
}