]> Sergey Matveev's repositories - public-inbox.git/blobdiff - t/v2reindex.t
imap: *SEARCH: fix CHARSET handling
[public-inbox.git] / t / v2reindex.t
index b97c6498c27b085c029b792392e10c5181b422a3..77deffb4ba9d780bc837a69d01028bea96f02f21 100644 (file)
@@ -3,8 +3,8 @@
 use strict;
 use warnings;
 use Test::More;
-use PublicInbox::MIME;
-use PublicInbox::ContentId qw(content_digest);
+use PublicInbox::Eml;
+use PublicInbox::ContentHash qw(content_digest);
 use File::Path qw(remove_tree);
 use PublicInbox::TestCommon;
 require_git(2.6);
@@ -24,7 +24,7 @@ my $agpl = do {
        <$fh>;
 };
 my $phrase = q("defending all users' freedom");
-my $mime = PublicInbox::MIME->new(<<'EOF'.$agpl);
+my $mime = PublicInbox::Eml->new(<<'EOF'.$agpl);
 From: a@example.com
 To: test@example.com
 Subject: this is a subject
@@ -38,7 +38,7 @@ my ($mark1, $mark2, $mark3, $mark4);
        my %config = %$ibx_config;
        my $ibx = PublicInbox::Inbox->new(\%config);
        my $im = PublicInbox::V2Writable->new($ibx, {nproc => 1});
-       my $im0 = $im->importer();
+       my $im0 = $im->importer(0);
        foreach my $i (1..10) {
                $mime->header_set('Message-Id', "<$i\@example.com>");
                ok($im->add($mime), "message $i added");
@@ -434,7 +434,7 @@ ok(!-d $xap, 'Xapian directories removed again');
        $config{indexlevel} = 'medium';
        my $ibx = PublicInbox::Inbox->new(\%config);
        my $im = PublicInbox::V2Writable->new($ibx);
-       my $m3 = PublicInbox::MIME->new(<<'EOF');
+       my $m3 = PublicInbox::Eml->new(<<'EOF');
 Date: Tue, 24 May 2016 14:34:22 -0700 (PDT)
 Message-Id: <20160524.143422.552507610109476444.d@example.com>
 To: t@example.com
@@ -465,7 +465,7 @@ Somehow we got a message with 3 sets of headers into one
 message, could've been something broken on the archiver side.
 EOF
 
-       my $m1 = PublicInbox::MIME->new(<<'EOF');
+       my $m1 = PublicInbox::Eml->new(<<'EOF');
 From: a@example.com
 To: t@example.com
 Subject: [PATCH 12/13]