Last change
on this file since 18037 was 18037, checked in by Don-vip, 3 years ago |
fix #21064 - Add JUnit 5 extension for preferences (patch by taylor.smock)
|
-
Property svn:eol-style
set to
native
|
File size:
855 bytes
|
Line | |
---|
1 | // License: GPL. For details, see LICENSE file.
|
---|
2 | package org.openstreetmap.josm.io.auth;
|
---|
3 |
|
---|
4 | import static org.junit.jupiter.api.Assertions.assertEquals;
|
---|
5 |
|
---|
6 | import org.junit.jupiter.api.Test;
|
---|
7 |
|
---|
8 | /**
|
---|
9 | * Unit tests of {@link CredentialsAgentException} class.
|
---|
10 | */
|
---|
11 | class CredentialsAgentExceptionTest {
|
---|
12 | /**
|
---|
13 | * Unit test of {@code CredentialsAgentException#CredentialsAgentException}
|
---|
14 | */
|
---|
15 | @Test
|
---|
16 | void testCredentialsAgentException() {
|
---|
17 | String msg = "test1";
|
---|
18 | Exception cause = new Exception("test2");
|
---|
19 | assertEquals(msg, new CredentialsAgentException(msg).getMessage());
|
---|
20 | assertEquals(cause, new CredentialsAgentException(cause).getCause());
|
---|
21 | CredentialsAgentException exc = new CredentialsAgentException(msg, cause);
|
---|
22 | assertEquals(msg, exc.getMessage());
|
---|
23 | assertEquals(cause, exc.getCause());
|
---|
24 | }
|
---|
25 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.