- is(system(@xcpdb, "-R$R", $ibx->{mainrepo}), 0, "xcpdb -R$R");
- my @new_shards = grep(m!/\d+\z!, glob("$ibx->{mainrepo}/xap*/*"));
+ my $cmd = [@xcpdb, "-R$R", $ibx->{inboxdir}];
+ push @$cmd, '--compact' if $R == 1;
+ ok(run_script($cmd), "xcpdb -R$R");
+ my @new_shards = grep(m!/\d+\z!, glob("$ibx->{inboxdir}/xap*/*"));