# ensure conflicted attachments can be resolved
foreach my $body (qw(old new)) {
- my $parts = [
- PublicInbox::MIME->create(
- attributes => { content_type => 'text/plain' },
- body => 'blah',
- ),
- PublicInbox::MIME->create(
- attributes => {
- filename => 'attach.txt',
- content_type => 'text/plain',
- },
- body => $body
- )
- ];
- $mime = PublicInbox::MIME->create(
- parts => $parts,
- header_str => [ From => 'root@z',
- 'Message-ID' => '<a@dup>',
- Subject => 'hi']
- );
+ $mime = mime_load "t/psgi_v2-$body.eml";
ok($im->add($mime), "added attachment $body");
}
$im->done;