use of com.google.gerrit.entities.Address in project gerrit by GerritCodeReview.
the class FromAddressGeneratorProviderTest method CUSTOM_FullyConfiguredUser.
@Test
public void CUSTOM_FullyConfiguredUser() {
setFrom("A ${user} B <my.server@email.address>");
final String name = "A U. Thor";
final String email = "a.u.thor@test.example.com";
final Account.Id user = user(name, email);
final Address r = create().from(user);
assertThat(r).isNotNull();
assertThat(r.name()).isEqualTo("A " + name + " B");
assertThat(r.email()).isEqualTo("my.server@email.address");
verifyAccountCacheGet(user);
}
Aggregations