| | 292 | |
| | 293 | /// |
| | 294 | /// @brief Test loading a relative path filename. |
| | 295 | /// |
| | 296 | /// Poppler's glib wrapper needs an URI instead of just a filename, but |
| | 297 | /// in order to build it I need an absolute path. This check test that |
| | 298 | /// giving a relative path converts it to absolute and loads the file |
| | 299 | /// properly. |
| | 300 | /// |
| | 301 | void |
| | 302 | PDFDocumentTest::relativePath () |
| | 303 | { |
| | 304 | CPPUNIT_ASSERT (m_Document->loadFile (TEST_DIR "test1.pdf", NULL, NULL)); |
| | 305 | CPPUNIT_ASSERT (m_Document->isLoaded ()); |
| | 306 | CPPUNIT_ASSERT_EQUAL (0, |
| | 307 | g_ascii_strcasecmp (TEST_DIR "test1.pdf", |
| | 308 | m_Document->getFileName ())); |
| | 309 | } |
| | 310 | |