Changeset 193
- Timestamp:
- 05/27/06 10:01:06 (2 years ago)
- Files:
-
- trunk/tests/ConfigTest.cxx (modified) (2 diffs)
- trunk/tests/ConfigTest.h (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/tests/ConfigTest.cxx
r100 r193 57 57 CPPUNIT_ASSERT_EQUAL (600, config.getWindowWidth ()); 58 58 CPPUNIT_ASSERT_EQUAL (650, config.getWindowHeight ()); 59 CPPUNIT_ASSERT ( config.showToolbar ());60 CPPUNIT_ASSERT ( config.showStatusbar ());59 CPPUNIT_ASSERT (config.showToolbar ()); 60 CPPUNIT_ASSERT (config.showStatusbar ()); 61 61 CPPUNIT_ASSERT_EQUAL ((gchar *)NULL, config.getOpenFileFolder ()); 62 CPPUNIT_ASSERT ( !config.zoomToWidth () ); 63 CPPUNIT_ASSERT ( !config.zoomToFit () ); 62 CPPUNIT_ASSERT (!config.zoomToWidth ()); 63 CPPUNIT_ASSERT (!config.zoomToFit ()); 64 65 gchar *commandLine = config.getExternalBrowserCommandLine (); 66 CPPUNIT_ASSERT (0 == g_ascii_strcasecmp ("firefox %s", commandLine)); 67 g_free (commandLine); 64 68 } 65 69 … … 159 163 CPPUNIT_ASSERT ( !config.zoomToFit () ); 160 164 } 165 166 /// 167 /// @brief Checks setting the external browser command line. 168 /// 169 void 170 ConfigTest::externalBrowser () 171 { 172 Config &config = Config::getConfig (); 173 174 config.setExternalBrowserCommandLine ("galeon %s"); 175 gchar *commandLine = config.getExternalBrowserCommandLine (); 176 CPPUNIT_ASSERT ( 0 == g_ascii_strcasecmp ("galeon %s", commandLine)); 177 g_free (commandLine); 178 179 config.setExternalBrowserCommandLine ("xterm -e lynx %s"); 180 commandLine = config.getExternalBrowserCommandLine (); 181 CPPUNIT_ASSERT ( 0 == g_ascii_strcasecmp ("xterm -e lynx %s", commandLine)); 182 g_free (commandLine); 183 } trunk/tests/ConfigTest.h
r100 r193 32 32 CPPUNIT_TEST (currentFolder); 33 33 CPPUNIT_TEST (zoomValues); 34 CPPUNIT_TEST (externalBrowser); 34 35 CPPUNIT_TEST_SUITE_END (); 35 36 … … 44 45 void currentFolder (void); 45 46 void zoomValues (void); 47 void externalBrowser (void); 46 48 }; 47 49 }
