* [PATCH] t/v2writable.t: force more consistent "git log" output
@ 2019-01-10 3:26 Eric Wong
0 siblings, 0 replies; only message in thread
From: Eric Wong @ 2019-01-10 3:26 UTC (permalink / raw)
To: meta; +Cc: Johannes Berg
This should probably use lower-level git plumbing, but until
then, consistently add a bunch of --no-* options to "git log"
to get more consistent output.
Noticed-by: Johannes Berg
https://public-inbox.org/meta/1538164205.14416.76.camel@sipsolutions.net/
---
t/v2writable.t | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
diff --git a/t/v2writable.t b/t/v2writable.t
index c7eeee9..a649a5b 100644
--- a/t/v2writable.t
+++ b/t/v2writable.t
@@ -201,13 +201,14 @@ EOF
};
{
local $ENV{NPROC} = 2;
- my @before = $git0->qx(qw(log --pretty=oneline));
- my $before = $git0->qx(qw(log --pretty=raw --raw -r --no-abbrev));
+ my @log = qw(log --no-decorate --no-abbrev --no-notes --no-color);
+ my @before = $git0->qx(@log, qw(--pretty=oneline));
+ my $before = $git0->qx(@log, qw(--pretty=raw --raw -r));
$im = PublicInbox::V2Writable->new($ibx, 1);
is($im->{partitions}, 1, 'detected single partition from previous');
my $smsg = $im->remove($mime, 'test removal');
$im->done;
- my @after = $git0->qx(qw(log --pretty=oneline));
+ my @after = $git0->qx(@log, qw(--pretty=oneline));
my $tip = shift @after;
like($tip, qr/\A[a-f0-9]+ test removal\n\z/s,
'commit message propagated to git');
@@ -219,7 +220,7 @@ EOF
my $srch = $ibx->search->reopen;
my $mset = $srch->query('m:'.$smsg->mid, { mset => 1});
is($mset->size, 0, 'no longer found in Xapian');
- my @log1 = qw(log -1 --pretty=raw --raw -r --no-abbrev --no-renames);
+ my @log1 = (@log, qw(-1 --pretty=raw --raw -r --no-renames));
is($srch->{over_ro}->get_art($num), undef,
'removal propagated to Over DB');
--
EW
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2019-01-10 3:26 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-01-10 3:26 [PATCH] t/v2writable.t: force more consistent "git log" output Eric Wong
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).