Add a test for "%e" to wxDateTime::ParseFormat()
See https://github.com/wxWidgets/wxWidgets/pull/1842
This commit is contained in:
@@ -868,6 +868,10 @@ void DateTimeTestCase::TestTimeFormat()
|
||||
CPPUNIT_ASSERT( dt.ParseFormat("12:23:45.000", "%H:%M:%S.%l") );
|
||||
CPPUNIT_ASSERT_EQUAL( 0, dt.GetMillisecond() );
|
||||
|
||||
// test another format modifier not testes above.
|
||||
CPPUNIT_ASSERT( dt.ParseFormat("23", "%e") );
|
||||
CPPUNIT_ASSERT_EQUAL( 23, dt.GetDay() );
|
||||
|
||||
// test partially specified dates too
|
||||
wxDateTime dtDef(26, wxDateTime::Sep, 2008);
|
||||
CPPUNIT_ASSERT( dt.ParseFormat("17", "%d", dtDef) );
|
||||
|
Reference in New Issue
Block a user