From 2f1a6c43f9bb600ffc622f2ac2f8bcd66b5d212f Mon Sep 17 00:00:00 2001 From: Nick Clemens Date: Fri, 13 Sep 2024 17:43:07 +0000 Subject: [PATCH] Bug 37796: Adjust unit tests --- t/db_dependent/Serials.t | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/t/db_dependent/Serials.t b/t/db_dependent/Serials.t index 0c9ce3dffef..9e7c5c261d1 100755 --- a/t/db_dependent/Serials.t +++ b/t/db_dependent/Serials.t @@ -631,14 +631,16 @@ subtest "test numbering pattern with dates in GetSeq GetNextSeq" => sub { 'GetSeq correctly calculates numbering from first aqui date, leap year' ); - my $planneddate = '1970-11-01'; - ($numbering) = GetNextSeq( $subscription, $pattern, undef, $planneddate ); - is( $numbering, '1970 1 Sunday 11 November', 'GetNextSeq correctly calculates numbering from planned date' ); - $planneddate = '2024-02-29'; - ($numbering) = GetNextSeq( $subscription, $pattern, undef, $planneddate ); + my $planneddate = '1970-10-01'; + my $nextpublisheddate = '1970-11-01'; + ($numbering) = GetNextSeq( $subscription, $pattern, undef, $planneddate, $nextpublisheddate ); + is( $numbering, '1970 1 Sunday 11 November', 'GetNextSeq correctly calculates numbering from next published date' ); + $planneddate = '2024-01-29'; + $nextpublisheddate = '2024-02-29'; + ($numbering) = GetNextSeq( $subscription, $pattern, undef, $planneddate, $nextpublisheddate ); is( $numbering, '2024 29 Thursday 2 February', - 'GetNextSeq correctly calculates numbering from planned date, leap year' + 'GetNextSeq correctly calculates numbering from next published date, leap year' ); }; -- 2.39.2