Skip Menu |
 

This queue is for tickets about the File-Find-Rule-Age CPAN distribution.

Report information
The Basics
Id: 106579
Status: open
Priority: 0/
Queue: File-Find-Rule-Age

People
Owner: Nobody in particular
Requestors: MOTOTIMO [...] cpan.org
Cc: contyk [...] cpan.org
AdminCc:

Bug Information
Severity: Important
Broken in: (no value)
Fixed in: (no value)



CC: contyk [...] cpan.org
Subject: 02-modified.t intermittent test failure
Download (untitled) / with headers
text/plain 778b
About 6% of the time, the last test in 02-modified.t fails. --- is_deeply( \@fl, ['yesterday'], "modified_before lastday (DateTime::Duration)" ) or diag( explain( \@fl ) ); --- The failure is: # Failed test 'modified_before lastday (DateTime::Duration)' # at t/02-modified.t line 167. # Structures begin differing at: # $got->[1] = 'lastday' # $expected->[1] = Does not exist # [ # 'yesterday', # 'lastday' # ] # Looks like you failed 1 test of 24. t/02-modified.t .. See, for instance, https://apps.fedoraproject.org/koschei/package/perl-File-Find-Rule-Age I have seen this failure---at about the same frequency---in several Fedora releases, so it seems it is the specific test step and not directly related to some specific dependency revision.
Download (untitled) / with headers
text/plain 1.1k
I added a loop to my spec file to test this many times in the mockbuild environment: ---- FAIL=0 COUNT=0 function my_trap_handler() { FAIL=$((FAIL+1)) } set +e for i in {0..1000}; do perl -Mblib t/02-modified.t trap my_trap_handler ERR COUNT=$((COUNT+1)) FAIL=$FAIL done PASS=$((COUNT-FAIL)) FAIL=$FAIL set -e --- The result for one run was PASS=970 FAIL=31 These failures were a mix of: not ok 4 - modified_since now (DateTime::Duration) # Failed test 'modified_since now (DateTime::Duration)' # at t/02-modified.t line 66. # Structures begin differing at: # $got->[0] = Does not exist # $expected->[0] = 'now' # [] not ok 22 - modified_before lastday (DateTime::Duration) # Failed test 'modified_before lastday (DateTime::Duration)' # at t/02-modified.t line 167. # Structures begin differing at: # $got->[1] = 'lastday' # $expected->[1] = Does not exist # [ # 'yesterday', # 'lastday' # ] Sometimes both fail in the same run. 22 is more common. I'd have to get a bit more creative to give the breakdown of each. I have also see failures of 24, but not in this run. Let me know a more helpful way to diagnose this :)
Download (untitled) / with headers
text/plain 1.3k
On 2015-08-21 09:28:27, MOTOTIMO wrote: Show quoted text
> About 6% of the time, the last test in 02-modified.t fails. > --- > is_deeply( \@fl, ['yesterday'], "modified_before lastday > (DateTime::Duration)" ) > or diag( explain( \@fl ) ); > --- > > The failure is: > > # Failed test 'modified_before lastday (DateTime::Duration)' > # at t/02-modified.t line 167. > # Structures begin differing at: > # $got->[1] = 'lastday' > # $expected->[1] = Does not exist > # [ > # 'yesterday', > # 'lastday' > # ] > # Looks like you failed 1 test of 24. > t/02-modified.t .. > > See, for instance, > https://apps.fedoraproject.org/koschei/package/perl-File-Find-Rule-Age > > I have seen this failure---at about the same frequency---in several > Fedora releases, so it seems it is the specific test step and not > directly related to some specific dependency revision.
The test fails 100% of the time if some delay is added: diff --git a/t/02-modified.t b/t/02-modified.t index 496176c..084496b 100644 --- a/t/02-modified.t +++ b/t/02-modified.t @@ -59,6 +59,7 @@ is_deeply( \@fl, ['now'], "modified_since now (Number)" ) or diag( explain( \@fl relative => in => $dir_name ); is_deeply( \@fl, ['now'], "modified_since now (DateTime)" ) or diag( explain( \@fl ) ); +sleep 1; @fl = find( file => modified_since => $now - $now, relative => in => $dir_name


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.