diff options
author | Tor Lillqvist <tlillqvist@novell.com> | 2011-05-15 12:51:40 +0300 |
---|---|---|
committer | Tor Lillqvist <tlillqvist@novell.com> | 2011-05-15 12:51:53 +0300 |
commit | a727681c02dbac90022c0da8d1d1e9b241303d62 (patch) | |
tree | 6479a3f676b4f3ebc56f5442c55b460298f32d0c /lotuswordpro/qa | |
parent | ff19ab5a45dab887b4aca2d58335b1e64e5425ab (diff) |
Fix lotuswordpro unit test on Windows
file: URLs on Windows are of the form file:///c:/path/to/file , and
the SRC_ROOT environment variable is of the form C:/lo/git/master, so
we can't just concatenate "file://" and SRC_ROOT, but have to insert a
"/".
Windows programs don't understand Cygwin symlinks, so we have to
specify the path from SRC_ROOT to lotuswordpro through an explicit
clone/filters path.
Diffstat (limited to 'lotuswordpro/qa')
-rw-r--r-- | lotuswordpro/qa/cppunit/test_lotuswordpro.cxx | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/lotuswordpro/qa/cppunit/test_lotuswordpro.cxx b/lotuswordpro/qa/cppunit/test_lotuswordpro.cxx index 55916559dedf..276625397487 100644 --- a/lotuswordpro/qa/cppunit/test_lotuswordpro.cxx +++ b/lotuswordpro/qa/cppunit/test_lotuswordpro.cxx @@ -82,6 +82,10 @@ namespace const char* pSrcRoot = getenv( "SRC_ROOT" ); CPPUNIT_ASSERT_MESSAGE("SRC_ROOT env variable not set", pSrcRoot != NULL && pSrcRoot[0] != 0); +#ifdef WNT + if (pSrcRoot[1] == ':') + m_aSrcRoot += rtl::OUString::createFromAscii( "/" ); +#endif m_aSrcRoot += rtl::OUString::createFromAscii( pSrcRoot ); //Without this we're crashing because callees are using @@ -143,8 +147,8 @@ namespace void LotusWordProTest::test() { - recursiveScan(m_aSrcRoot + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("/lotuswordpro/qa/cppunit/data/pass")), true); - recursiveScan(m_aSrcRoot + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("/lotuswordpro/qa/cppunit/data/fail/")), false); + recursiveScan(m_aSrcRoot + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("/clone/filters/lotuswordpro/qa/cppunit/data/pass")), true); + recursiveScan(m_aSrcRoot + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("/clone/filters/lotuswordpro/qa/cppunit/data/fail/")), false); printf("LotusWordPro: tested %d files\n", m_nLoadedDocs); } |