Skip to content

Commit

Permalink
call assertEquals with parameters in the right order
Browse files Browse the repository at this point in the history
  • Loading branch information
dfuch committed Jul 2, 2024
1 parent 6b944e6 commit f042b05
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions test/jdk/com/sun/net/httpserver/AuthenticatorTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -40,20 +40,20 @@ public class AuthenticatorTest {
@Test
public void testFailure() {
var failureResult = new Authenticator.Failure(666);
assertEquals(failureResult.getResponseCode(), 666);
assertEquals(666, failureResult.getResponseCode(), );
}

@Test
public void testRetry() {
var retryResult = new Authenticator.Retry(333);
assertEquals(retryResult.getResponseCode(), 333);
assertEquals(333, retryResult.getResponseCode());
}

@Test
public void testSuccess() {
var principal = new HttpPrincipal("test", "123");
var successResult = new Authenticator.Success(principal);
assertEquals(successResult.getPrincipal(), principal);
assertEquals(principal, successResult.getPrincipal());
assertEquals("test", principal.getUsername());
assertEquals("123", principal.getRealm());
}
Expand Down

0 comments on commit f042b05

Please sign in to comment.