diff options
author | Eike Rathke <erack@redhat.com> | 2011-12-01 23:00:07 +0100 |
---|---|---|
committer | Eike Rathke <erack@redhat.com> | 2011-12-01 23:00:37 +0100 |
commit | a97a5310f921a483d0d11a98cd18185890bcccbc (patch) | |
tree | 37109f908424c448db3f3f1ff3227033b0fff067 /sax/qa | |
parent | 44ec239eba3b652fc8dbe1e0eb66c7f9ed018137 (diff) |
we are W3C XMLSchema here, not ISO 8601
Diffstat (limited to 'sax/qa')
-rw-r--r-- | sax/qa/cppunit/test_converter.cxx | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/sax/qa/cppunit/test_converter.cxx b/sax/qa/cppunit/test_converter.cxx index 17d1303e901c..64bbf2918d69 100644 --- a/sax/qa/cppunit/test_converter.cxx +++ b/sax/qa/cppunit/test_converter.cxx @@ -215,13 +215,11 @@ void ConverterTest::testDateTime() doTest( util::DateTime(0, 0, 0, 24, 1, 1, 333) /*(0, 0, 0, 0, 2, 1, 333)*/, "0333-01-01T24:00:00"/*, "0333-01-02T00:00:00"*/ ); - // A leading ^+ is NOT invalid, ISO 8601 specifies this for explicit AD/CE. - doTest( util::DateTime(0, 0, 0, 0, 1, 1, 1), - "+0001-01-01T00:00:00", "0001-01-01T00:00:00" ); - // While ISO 8601 specifies a minimum of 4 year digits we are lenient in - // what we accept. + // While W3C XMLSchema specifies a minimum of 4 year digits we are lenient + // in what we accept. doTest( util::DateTime(0, 0, 0, 0, 1, 1, 1), "1-01-01T00:00:00", "0001-01-01T00:00:00" ); + doTestDateTimeF( "+0001-01-01T00:00:00" ); // invalid: ^+ doTestDateTimeF( "0001-1-01T00:00:00" ); // invalid: < 2 M doTestDateTimeF( "0001-01-1T00:00:00" ); // invalid: < 2 D doTestDateTimeF( "0001-01-01T0:00:00" ); // invalid: < 2 H |