develooper Front page | perl.perl5.porters | Postings from February 2020

Re: How to bisect for first commit at which a test passes?

Thread Previous | Thread Next
From:
hv
Date:
February 1, 2020 20:33
Subject:
Re: How to bisect for first commit at which a test passes?
Message ID:
202002012016.011KGXP27064@crypt.org
I wrote:
:James E Keenan <jkeenan@pobox.com> wrote:
:[...]
::perl Porting/bisect.pl --start=v5.31.2 --end=v5.31.3 \
::-Dcc="g++7" \
::-Accflags="-Wl,-rpath=/usr/local/lib/gcc7" \
::-Aldflags="-Wl,-rpath=/usr/local/lib/gcc7" \
::--expect-fail --target t/op/sprintf2.t
::
::But that ends with this:
::
::t/op/sprintf2 ... ok
::All tests successful.
::Elapsed: 1 sec
::u=0.02  s=0.00  cu=0.24  cs=0.07  scripts=1  tests=1699
::HEAD is now at 45e0524192 5.31.2 today
::bad - zero exit from sh -c cd t && ./perl TEST op\/sprintf2\.t
::Runner returned 256, not 0 for start revision at 
:
:That looks to me like it's saying the test passed at the start revision,
:v5.31.2, unexpectedly.

To expand on that: expect-fail is implemented by setting expect-pass to 0,
and then handled in bisect-runner.pl report_and_exit(), where it is used
to invert the return value seen by bisect.pl.

So the test passed, the test run returned 0, so report_and_exit returned
non-zero, and that's why it complains "Runner returned 256, not 0 for start
revision".

Hugo

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About