]> git.saurik.com Git - wxWidgets.git/blobdiff - tests/strings/strings.cpp
don't use WPARAM in the header (build fix after r59336)
[wxWidgets.git] / tests / strings / strings.cpp
index 3542704e49cea77d7aca63941bbfc617fd94bae2..09686b11da5b493e6d854e7f2ec6cc4023a5d5a2 100644 (file)
@@ -531,7 +531,7 @@ enum
     Number_Unsigned = 2,    // if not specified, works for signed conversion
     Number_Signed   = 4,    // if not specified, works for unsigned
     Number_LongLong = 8,    // only for long long tests
-    Number_Long     = 16,   // only for long tests
+    Number_Long     = 16    // only for long tests
 };
 
 static const struct ToLongData
@@ -834,33 +834,33 @@ void StringTestCase::ExplicitConversion()
 void StringTestCase::IndexedAccess()
 {
     wxString s("bar");
-    CPPUNIT_ASSERT_EQUAL( 'r', s[2] );
+    CPPUNIT_ASSERT_EQUAL( 'r', (char)s[2] );
 
     // this tests for a possible bug in UTF-8 based wxString implementation:
     // the 3rd character of the underlying byte string is going to change, but
     // the 3rd character of wxString should remain the same
-    s[0] = L'\u00e9';
-    CPPUNIT_ASSERT_EQUAL( 'r', s[2] );
+    s[0] = L'\xe9';
+    CPPUNIT_ASSERT_EQUAL( 'r', (char)s[2] );
 }
 
 void StringTestCase::BeforeAndAfter()
 {
-    const wxString s(L"letter=\u00e9;\u00e7a=l\u00e0");
+    const wxString s(L"letter=\xe9;\xe7a=l\xe0");
 
     CPPUNIT_ASSERT_EQUAL( "letter", s.BeforeFirst('=') );
     CPPUNIT_ASSERT_EQUAL( s, s.BeforeFirst('!') );
-    CPPUNIT_ASSERT_EQUAL( L"letter=\u00e9", s.BeforeFirst(';') );
+    CPPUNIT_ASSERT_EQUAL( L"letter=\xe9", s.BeforeFirst(';') );
 
-    CPPUNIT_ASSERT_EQUAL( L"letter=\u00e9;\u00e7a", s.BeforeLast('=') );
+    CPPUNIT_ASSERT_EQUAL( L"letter=\xe9;\xe7a", s.BeforeLast('=') );
     CPPUNIT_ASSERT_EQUAL( "", s.BeforeLast('!') );
-    CPPUNIT_ASSERT_EQUAL( L"letter=\u00e9", s.BeforeLast(';') );
+    CPPUNIT_ASSERT_EQUAL( L"letter=\xe9", s.BeforeLast(';') );
 
-    CPPUNIT_ASSERT_EQUAL( L"\u00e9;\u00e7a=l\u00e0", s.AfterFirst('=') );
+    CPPUNIT_ASSERT_EQUAL( L"\xe9;\xe7a=l\xe0", s.AfterFirst('=') );
     CPPUNIT_ASSERT_EQUAL( "", s.AfterFirst('!') );
-    CPPUNIT_ASSERT_EQUAL( L"\u00e7a=l\u00e0", s.AfterFirst(';') );
+    CPPUNIT_ASSERT_EQUAL( L"\xe7a=l\xe0", s.AfterFirst(';') );
 
-    CPPUNIT_ASSERT_EQUAL( L"l\u00e0", s.AfterLast('=') );
+    CPPUNIT_ASSERT_EQUAL( L"l\xe0", s.AfterLast('=') );
     CPPUNIT_ASSERT_EQUAL( s, s.AfterLast('!') );
-    CPPUNIT_ASSERT_EQUAL( L"\u00e7a=l\u00e0", s.AfterLast(';') );
+    CPPUNIT_ASSERT_EQUAL( L"\xe7a=l\xe0", s.AfterLast(';') );
 }