Subject: | Possible bug under parallel testing ( HARNESS_OPTIONS=j<n> ) |
I've just hit this a few times. Its hard to make happen guaranteedly, because it seems to be random, and race condition dependent.
I know for instance, if you run tests t/03_deep_readonly.t and t/04_can_delete.t, you'll only get a failure about 10% of the time.
while true; do prove -bj2 t/03_deep_readonly.t t/04_can_delete.t ; done
Attached, are a bunch of failure outputs that doing this results in.
Subject: | failure_1.txt |
===( 9;0 8/12 1/12 )==========================================
# Failed test 'Created t/d1 -w'
# at t/04_can_delete.t line 33.
Failed to create t/d1/d2 at t/04_can_delete.t line 34.
# Looks like you planned 12 tests but ran 4.
# Looks like you failed 1 test of 4 run.
# Looks like your test exited with 2 just after 4.
t/04_can_delete.t ..... Dubious, test returned 2 (wstat 512, 0x200)
Failed 9/12 subtests
t/03_deep_readonly.t .. ok
Test Summary Report
-------------------
t/04_can_delete.t (Wstat: 512 Tests: 4 Failed: 1)
Failed test: 4
Non-zero exit status: 2
Parse errors: Bad plan. You planned 12 tests but ran 4.
Files=2, Tests=16, 1 wallclock secs ( 0.03 usr 0.01 sys + 0.08 cusr 0.02 csys = 0.14 CPU)
Result: FAIL
Subject: | failure_2.txt |
===( 3;0 2/12 1/12 )==========================================Failed to create t/d1/d2 at t/03_deep_readonly.t line 34.
# Looks like you planned 12 tests but ran 4.
# Looks like your test exited with 2 just after 4.
t/03_deep_readonly.t .. Dubious, test returned 2 (wstat 512, 0x200)
Failed 8/12 subtests
t/04_can_delete.t ..... ok
Test Summary Report
-------------------
t/03_deep_readonly.t (Wstat: 512 Tests: 4 Failed: 0)
Non-zero exit status: 2
Parse errors: Bad plan. You planned 12 tests but ran 4.
Subject: | failure_3.txt |
===( 4;0 3/12 1/12 )==========================================
# Failed test 'Created t/d1/d2 -r'
# at t/03_deep_readonly.t line 36.
# Failed test 'Created t/d1/d2 -w'
# at t/03_deep_readonly.t line 37.
t/04_can_delete.t ..... ok
t/03_deep_readonly.t .. 10/12
# Failed test 'remove('t/d1') ok'
# at t/03_deep_readonly.t line 89.
# Looks like you failed 3 tests of 12.
t/03_deep_readonly.t .. Dubious, test returned 3 (wstat 768, 0x300)
Failed 3/12 subtests
Test Summary Report
-------------------
t/03_deep_readonly.t (Wstat: 768 Tests: 12 Failed: 3)
Failed tests: 6-7, 11
Non-zero exit status: 3
Subject: | failure_4.txt |
===( 10;0 9/12 1/12 )==========================================
# Failed test 'Created t/d1/d2/f3.txt ok'
# at t/04_can_delete.t line 41.
# Failed test 'Created t/d1/d2/f3.txt -r'
# at t/04_can_delete.t line 42.
# Looks like you failed 2 tests of 12.
t/04_can_delete.t ..... Dubious, test returned 2 (wstat 512, 0x200)
Failed 2/12 subtests
t/03_deep_readonly.t .. ok
Test Summary Report
-------------------
t/04_can_delete.t (Wstat: 512 Tests: 12 Failed: 2)
Failed tests: 8-9
Non-zero exit status: 2