From b0491d86706fee2367309a8d3b029973c5d5f56e Mon Sep 17 00:00:00 2001 From: Julian Maurice Date: Mon, 9 Feb 2015 16:02:29 +0100 Subject: [PATCH] Bug 11708: Add descriptions in unit tests Signed-off-by: Paola Rossi --- t/db_dependent/Acquisition/Basketgroups.t | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/t/db_dependent/Acquisition/Basketgroups.t b/t/db_dependent/Acquisition/Basketgroups.t index 28196c6..a17a295c 100755 --- a/t/db_dependent/Acquisition/Basketgroups.t +++ b/t/db_dependent/Acquisition/Basketgroups.t @@ -22,27 +22,27 @@ my $basketgroupid = NewBasketgroup({ }); my $basketgroup = GetBasketgroup($basketgroupid); -ok(!$basketgroup->{closed}); -ok(!defined($basketgroup->{closeddate})); +ok(!$basketgroup->{closed}, "basket group is open"); +ok(!defined($basketgroup->{closeddate}), "basket group closed date is empty"); CloseBasketgroup($basketgroupid); $basketgroup = GetBasketgroup($basketgroupid); -ok($basketgroup->{closed}); -ok(defined($basketgroup->{closeddate})); +ok($basketgroup->{closed}, "basket group is closed"); +ok(defined($basketgroup->{closeddate}), "basket group closed date is not empty"); my ($day, $month, $year) = (localtime)[3,4,5]; -ok($basketgroup->{closeddate} eq sprintf("%04d-%02d-%02d", $year+1900, $month+1, $day)); +ok($basketgroup->{closeddate} eq sprintf("%04d-%02d-%02d", $year+1900, $month+1, $day), "basket group closed date is correct"); ReOpenBasketgroup($basketgroupid); $basketgroup = GetBasketgroup($basketgroupid); -ok(!$basketgroup->{closed}); -ok(!defined($basketgroup->{closeddate})); +ok(!$basketgroup->{closed}, "basket group is open"); +ok(!defined($basketgroup->{closeddate}), "basket group closed date is empty"); $basketgroup->{closed} = 1; ModBasketgroup($basketgroup); $basketgroup = GetBasketgroup($basketgroupid); -ok($basketgroup->{closed}); -ok(defined($basketgroup->{closeddate})); -ok($basketgroup->{closeddate} eq sprintf("%04d-%02d-%02d", $year+1900, $month+1, $day)); +ok($basketgroup->{closed}, "basket group is closed"); +ok(defined($basketgroup->{closeddate}), "basket group closed date is not empty"); +ok($basketgroup->{closeddate} eq sprintf("%04d-%02d-%02d", $year+1900, $month+1, $day), "basket group closed date is correct"); $basketgroupid = NewBasketgroup({ booksellerid => $booksellerid, @@ -50,8 +50,8 @@ $basketgroupid = NewBasketgroup({ closed => 1, }); $basketgroup = GetBasketgroup($basketgroupid); -ok($basketgroup->{closed}); -ok(defined($basketgroup->{closeddate})); -ok($basketgroup->{closeddate} eq sprintf("%04d-%02d-%02d", $year+1900, $month+1, $day)); +ok($basketgroup->{closed}, "basket group is closed"); +ok(defined($basketgroup->{closeddate}), "basket group closed date is not empty"); +ok($basketgroup->{closeddate} eq sprintf("%04d-%02d-%02d", $year+1900, $month+1, $day), "basket group closed date is correct"); $dbh->rollback; -- 1.7.10.4