mirror of
https://github.com/pgpainless/pgpainless.git
synced 2024-11-30 08:12:06 +01:00
More UserID tests
This commit is contained in:
parent
2880e0bed0
commit
87eab2fb9a
1 changed files with 11 additions and 0 deletions
|
@ -75,4 +75,15 @@ public class UserIdTest {
|
||||||
.withEmail("juliet@capulet.lit")
|
.withEmail("juliet@capulet.lit")
|
||||||
.toString());
|
.toString());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Test
|
||||||
|
public void throwIfOnlyEmailEmailNull() {
|
||||||
|
assertThrows(IllegalArgumentException.class, () -> UserId.onlyEmail(null));
|
||||||
|
}
|
||||||
|
|
||||||
|
@Test
|
||||||
|
public void testNameAndEmail() {
|
||||||
|
UserId userId = UserId.nameAndEmail("Maurice Moss", "moss.m@reynholm.co.uk");
|
||||||
|
assertEquals("Maurice Moss <moss.m@reynholm.co.uk>", userId.toString());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue