private:
CPPUNIT_TEST_SUITE( FileNameTestCase );
CPPUNIT_TEST( TestConstruction );
+ CPPUNIT_TEST( TestComparison );
CPPUNIT_TEST( TestSplit );
CPPUNIT_TEST( TestSetPath );
CPPUNIT_TEST( TestStrip );
CPPUNIT_TEST_SUITE_END();
void TestConstruction();
+ void TestComparison();
void TestSplit();
void TestSetPath();
void TestStrip();
}
}
+void FileNameTestCase::TestComparison()
+{
+ wxFileName fn1(wxT("/tmp/file1"));
+ wxFileName fn2(wxT("/tmp/dir2/../file2"));
+ fn1.Normalize();
+ fn2.Normalize();
+ CPPUNIT_ASSERT(fn1.GetPath() == fn2.GetPath());
+
+}
+
void FileNameTestCase::TestSplit()
{
for ( size_t n = 0; n < WXSIZEOF(filenames); n++ )