Show value if comparison fails in VarArgTestCase
Use string comparison instead of wxStrcmp() to view the actual value of the string if it doesn't have the expected value.
This commit is contained in:
@@ -206,12 +206,12 @@ void VarArgTestCase::Sscanf()
|
|||||||
|
|
||||||
wxSscanf(input, "%d %s", &i, &str);
|
wxSscanf(input, "%d %s", &i, &str);
|
||||||
CPPUNIT_ASSERT( i == 42 );
|
CPPUNIT_ASSERT( i == 42 );
|
||||||
CPPUNIT_ASSERT( wxStrcmp(str, "test") == 0 );
|
CPPUNIT_ASSERT( wxString(str) == "test" );
|
||||||
|
|
||||||
i = 0;
|
i = 0;
|
||||||
wxSscanf(input, L"%d %s", &i, &wstr);
|
wxSscanf(input, L"%d %s", &i, &wstr);
|
||||||
CPPUNIT_ASSERT( i == 42 );
|
CPPUNIT_ASSERT( i == 42 );
|
||||||
CPPUNIT_ASSERT( wxStrcmp(wstr, "test") == 0 );
|
CPPUNIT_ASSERT( wxString(wstr) == "test" );
|
||||||
}
|
}
|
||||||
|
|
||||||
void VarArgTestCase::RepeatedPrintf()
|
void VarArgTestCase::RepeatedPrintf()
|
||||||
|
Reference in New Issue
Block a user