about summary refs log tree commit homepage
path: root/t
diff options
context:
space:
mode:
Diffstat (limited to 't')
-rw-r--r--t/indexlevels-mirror.t2
-rw-r--r--t/psgi_v2.t2
-rw-r--r--t/v2writable.t4
-rw-r--r--t/view.t2
-rw-r--r--t/xcpdb-reshard.t14
5 files changed, 12 insertions, 12 deletions
diff --git a/t/indexlevels-mirror.t b/t/indexlevels-mirror.t
index 35974947..b685da14 100644
--- a/t/indexlevels-mirror.t
+++ b/t/indexlevels-mirror.t
@@ -138,7 +138,7 @@ sub import_index_incremental {
 
         if ($v == 2 && $level eq 'basic') {
                 is_deeply([glob("$ibx->{mainrepo}/xap*/?/")], [],
-                         'no Xapian partition directories for v2 basic');
+                         'no Xapian shard directories for v2 basic');
         }
         if ($level ne 'basic') {
                 ($nr, $msgs) = $ro_mirror->search->reopen->query('m:m@2');
diff --git a/t/psgi_v2.t b/t/psgi_v2.t
index b8062de2..a84566d9 100644
--- a/t/psgi_v2.t
+++ b/t/psgi_v2.t
@@ -205,7 +205,7 @@ test_psgi(sub { $www->call(@_) }, sub {
         $res = $cb->(GET('/v2test/0.git/info/refs'));
         is($res->code, 200, 'got info refs for dumb clones w/ .git suffix');
         $res = $cb->(GET('/v2test/info/refs'));
-        is($res->code, 404, 'unpartitioned git URL fails');
+        is($res->code, 404, 'v2 git URL w/o shard fails');
 
         # ensure conflicted attachments can be resolved
         foreach my $body (qw(old new)) {
diff --git a/t/v2writable.t b/t/v2writable.t
index b0f88d27..88df2d64 100644
--- a/t/v2writable.t
+++ b/t/v2writable.t
@@ -34,7 +34,7 @@ my $mime = PublicInbox::MIME->create(
 );
 
 my $im = PublicInbox::V2Writable->new($ibx, {nproc => 1});
-is($im->{partitions}, 1, 'one partition when forced');
+is($im->{shards}, 1, 'one shard when forced');
 ok($im->add($mime), 'ordinary message added');
 foreach my $f ("$mainrepo/msgmap.sqlite3",
                 glob("$mainrepo/xap*/*"),
@@ -199,7 +199,7 @@ EOF
         my @before = $git0->qx(@log, qw(--pretty=oneline));
         my $before = $git0->qx(@log, qw(--pretty=raw --raw -r));
         $im = PublicInbox::V2Writable->new($ibx, {nproc => 2});
-        is($im->{partitions}, 1, 'detected single partition from previous');
+        is($im->{shards}, 1, 'detected single shard from previous');
         my $smsg = $im->remove($mime, 'test removal');
         $im->done;
         my @after = $git0->qx(@log, qw(--pretty=oneline));
diff --git a/t/view.t b/t/view.t
index 07829543..d93be6f6 100644
--- a/t/view.t
+++ b/t/view.t
@@ -18,7 +18,7 @@ my $ctx = {
                 base_url => sub { 'http://example.com/' },
                 cloneurl => sub {[]},
                 nntp_url => sub {[]},
-                max_git_part => sub { undef },
+                max_git_epoch => sub { undef },
                 description => sub { '' }),
         www => Plack::Util::inline_object(style => sub { '' }),
 };
diff --git a/t/xcpdb-reshard.t b/t/xcpdb-reshard.t
index ce552f54..d921e12f 100644
--- a/t/xcpdb-reshard.t
+++ b/t/xcpdb-reshard.t
@@ -43,19 +43,19 @@ for my $i (1..$ndoc) {
         ok($im->add($mime), "message $i added");
 }
 $im->done;
-my @parts = grep(m!/\d+\z!, glob("$ibx->{mainrepo}/xap*/*"));
-is(scalar(@parts), $nproc, 'got expected parts');
+my @shards = grep(m!/\d+\z!, glob("$ibx->{mainrepo}/xap*/*"));
+is(scalar(@shards), $nproc, 'got expected shards');
 my $orig = $ibx->over->query_xover(1, $ndoc);
 my %nums = map {; "$_->{num}" => 1 } @$orig;
 
-# ensure we can go up or down in partitions, or stay the same:
+# ensure we can go up or down in shards, or stay the same:
 for my $R (qw(2 4 1 3 3)) {
         delete $ibx->{search}; # release old handles
         is(system(@xcpdb, "-R$R", $ibx->{mainrepo}), 0, "xcpdb -R$R");
-        my @new_parts = grep(m!/\d+\z!, glob("$ibx->{mainrepo}/xap*/*"));
-        is(scalar(@new_parts), $R, 'repartitioned to two parts');
+        my @new_shards = grep(m!/\d+\z!, glob("$ibx->{mainrepo}/xap*/*"));
+        is(scalar(@new_shards), $R, 'resharded to two shards');
         my $msgs = $ibx->search->query('s:this');
-        is(scalar(@$msgs), $ndoc, 'got expected docs after repartitioning');
+        is(scalar(@$msgs), $ndoc, 'got expected docs after resharding');
         my %by_mid = map {; "$_->{mid}" => $_ } @$msgs;
         ok($by_mid{"m$_\@example.com"}, "$_ exists") for (1..$ndoc);
 
@@ -64,7 +64,7 @@ for my $R (qw(2 4 1 3 3)) {
         # ensure docids in Xapian match NNTP article numbers
         my $tot = 0;
         my %tmp = %nums;
-        foreach my $d (@new_parts) {
+        foreach my $d (@new_shards) {
                 my $xdb = Search::Xapian::Database->new($d);
                 $tot += $xdb->get_doccount;
                 my $it = $xdb->postlist_begin('');