]> git.saurik.com Git - wxWidgets.git/blobdiff - tests/controls/textentrytest.cpp
use /nologo nmake switch to avoid many annoying copyright notices in output
[wxWidgets.git] / tests / controls / textentrytest.cpp
index 80e6482fa90d9efabc9ee5a4c5a6edfd127d7658..03adf476800945f205ff26db2b577cd3b1d130fe 100644 (file)
@@ -96,6 +96,11 @@ void TextEntryTestCase::TextChangeEvents()
     CPPUNIT_ASSERT_EQUAL( 1, handler.GetEvents() );
 }
 
+void TextEntryTestCase::CheckStringSelection(const char *sel)
+{
+    CPPUNIT_ASSERT_EQUAL( sel, GetTestEntry()->GetStringSelection() );
+}
+
 void TextEntryTestCase::AssertSelection(int from, int to, const char *sel)
 {
     wxTextEntry * const entry = GetTestEntry();
@@ -107,9 +112,10 @@ void TextEntryTestCase::AssertSelection(int from, int to, const char *sel)
     entry->GetSelection(&fromReal, &toReal);
     CPPUNIT_ASSERT_EQUAL( from, fromReal );
     CPPUNIT_ASSERT_EQUAL( to, toReal );
-    CPPUNIT_ASSERT_EQUAL( sel, entry->GetStringSelection() );
 
     CPPUNIT_ASSERT_EQUAL( from, entry->GetInsertionPoint() );
+
+    CheckStringSelection(sel);
 }
 
 void TextEntryTestCase::Selection()