summaryrefslogtreecommitdiff
path: root/t/03-date-handling.t
diff options
context:
space:
mode:
authortetragon <tetragon@4979c152-3d1c-0410-bac9-87ea11338e46>2007-05-07 06:12:03 +0000
committertetragon <tetragon@4979c152-3d1c-0410-bac9-87ea11338e46>2007-05-07 06:12:03 +0000
commit1362d71b4d88aed30dd797c86a1d215263796c1d (patch)
treec4fe2e3f13405f55886cf37827ce55c4edc9385e /t/03-date-handling.t
parent8dd214b61f500626b08b36acb22d116061ddb6fe (diff)
More test coverage
git-svn-id: https://ledger-smb.svn.sourceforge.net/svnroot/ledger-smb/branches/1.2@1149 4979c152-3d1c-0410-bac9-87ea11338e46
Diffstat (limited to 't/03-date-handling.t')
-rw-r--r--t/03-date-handling.t4
1 files changed, 4 insertions, 0 deletions
diff --git a/t/03-date-handling.t b/t/03-date-handling.t
index 68efe7dc..55fb4249 100644
--- a/t/03-date-handling.t
+++ b/t/03-date-handling.t
@@ -50,6 +50,7 @@ chomp $today_parts{'dd'};
# $locale->date checks
# Note that $locale->date assumes the year range 2000-2099
# Note that $locale->date does not perform language-specific long forms
+# Note that $locale->date also takes in yyyymmdd
foreach my $format (0 .. $#formats) {
%myconfig = (dateformat => $formats[$format][0]);
my $fmt = $formats[$format][0];
@@ -61,6 +62,8 @@ foreach my $format (0 .. $#formats) {
'', "date, $fmt: empty string");
cmp_ok($locale_en->date(\%myconfig, $formats[$format][3]), 'eq',
$result, "date, $fmt: short");
+ cmp_ok($locale_en->date(\%myconfig, '20000229'), 'eq',
+ $result, "date, $fmt: chopped");
for my $mm (1 .. 12) {
my $start = $fmt;
my $temp = sprintf('%02d', $mm);
@@ -78,6 +81,7 @@ foreach my $format (0 .. $#formats) {
}
# $form->current_date checks
+# Note that $form->current_date always uses the database
foreach my $format (0 .. $#formats) {
%myconfig = (dateformat => $formats[$format][0]);
my $fmt = $formats[$format][0];