Handle bad conversions correctly. Add Bad UTF8 test.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@30161 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -185,6 +185,14 @@ void StringTestCase::ConstructorsWithConversion()
|
||||
|
||||
CPPUNIT_ASSERT( s3 == sub );
|
||||
CPPUNIT_ASSERT( s4 == sub );
|
||||
|
||||
#if wxUSE_UNICODE
|
||||
CPPUNIT_ASSERT ( wxString("\t[pl]open.format.Sformatuj dyskietk<74>=gfloppy %f",
|
||||
wxConvUTF8) == wxT("") ); //Pos 35 (funky e) is invalid UTF8
|
||||
#else
|
||||
CPPUNIT_ASSERT ( wxString(L"\t[pl]open.format.Sformatuj dyskietk<74>=gfloppy %f",
|
||||
wxConvUTF8) == wxT("") ); //Pos 35 (funky e) is invalid UTF8
|
||||
#endif
|
||||
}
|
||||
|
||||
void StringTestCase::Conversion()
|
||||
|
Reference in New Issue
Block a user