} catch (MailBuilderException e) {
assertThat(e, exception("Could not find mail \"attachedMail\": no MailService"));
}
// ref
MailBuilder attached = new MailBuilder();
attached.setSubject("附件标题");
attached.setContent(new TextContent("我爱北京敏感词", "text/plain"));
MailService service = createMock(MailService.class);
expect(service.getMailBuilder("attachedMail")).andReturn(attached);
expect(service.getMailBuilder("notExistMail")).andThrow(new MailNotFoundException());
replay(service);