summaryrefslogtreecommitdiff
path: root/sw/qa/extras/uiwriter
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2017-02-09 08:52:13 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2017-06-21 08:42:30 +0200
commit528632660b72b105345945c13c5b68060d94a91b (patch)
tree860508d482959abeb9175f0ce6b9e65954269f95 /sw/qa/extras/uiwriter
parentaee66aa85e75f67135e5c6079a281e18402d261a (diff)
convert ErrCode to strong typedef
would have preferred to re-use o3tl::strong_int, of which this is a modified copy, but there are lots of convenience accessors which are nice to define on the class. Change-Id: I301b807aaf02fbced3bf75de1e1692cde6c0340a Reviewed-on: https://gerrit.libreoffice.org/38497 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sw/qa/extras/uiwriter')
-rw-r--r--sw/qa/extras/uiwriter/uiwriter.cxx12
1 files changed, 6 insertions, 6 deletions
diff --git a/sw/qa/extras/uiwriter/uiwriter.cxx b/sw/qa/extras/uiwriter/uiwriter.cxx
index 4654c2b0d968..0bd0ba789c19 100644
--- a/sw/qa/extras/uiwriter/uiwriter.cxx
+++ b/sw/qa/extras/uiwriter/uiwriter.cxx
@@ -749,7 +749,7 @@ void SwUiWriterTest::testImportRTF()
SwReader aReader(aStream, OUString(), OUString(), *pWrtShell->GetCursor());
Reader* pRTFReader = SwReaderWriter::GetRtfReader();
CPPUNIT_ASSERT(pRTFReader != nullptr);
- CPPUNIT_ASSERT_EQUAL(sal_uLong(0), aReader.Read(*pRTFReader));
+ CPPUNIT_ASSERT_EQUAL(ERRCODE_NONE, aReader.Read(*pRTFReader));
sal_uLong nIndex = pWrtShell->GetCursor()->GetNode().GetIndex();
CPPUNIT_ASSERT_EQUAL(OUString("fooHello world!"), pDoc->GetNodes()[nIndex - 1]->GetTextNode()->GetText());
@@ -1992,7 +1992,7 @@ void SwUiWriterTest::testTdf78742()
SfxMedium aMedium(path, StreamMode::READ | StreamMode::SHARE_DENYWRITE);
SfxFilterMatcher aMatcher("com.sun.star.text.TextDocument");
std::shared_ptr<const SfxFilter> pFilter;
- sal_uInt32 filter = aMatcher.DetectFilter(aMedium, pFilter);
+ ErrCode filter = aMatcher.DetectFilter(aMedium, pFilter);
CPPUNIT_ASSERT_EQUAL(ERRCODE_IO_ABORT, filter);
//it should not return any Filter
CPPUNIT_ASSERT(!pFilter);
@@ -2000,8 +2000,8 @@ void SwUiWriterTest::testTdf78742()
SfxMedium aMedium2(path, StreamMode::READ | StreamMode::SHARE_DENYWRITE);
SfxFilterMatcher aMatcher2;
std::shared_ptr<const SfxFilter> pFilter2;
- sal_uInt32 filter2 = aMatcher2.DetectFilter(aMedium2, pFilter2);
- CPPUNIT_ASSERT_EQUAL(ERRCODE_CLASS_NONE, filter2);
+ ErrCode filter2 = aMatcher2.DetectFilter(aMedium2, pFilter2);
+ CPPUNIT_ASSERT_EQUAL(ERRCODE_NONE, filter2);
//Filter should be returned with proper Name
CPPUNIT_ASSERT_EQUAL(OUString("calc8"), pFilter2->GetFilterName());
//testing with service type and any .odt file
@@ -2009,8 +2009,8 @@ void SwUiWriterTest::testTdf78742()
SfxMedium aMedium3(path2, StreamMode::READ | StreamMode::SHARE_DENYWRITE);
SfxFilterMatcher aMatcher3("com.sun.star.text.TextDocument");
std::shared_ptr<const SfxFilter> pFilter3;
- sal_uInt32 filter3 = aMatcher3.DetectFilter(aMedium3, pFilter3);
- CPPUNIT_ASSERT_EQUAL(ERRCODE_CLASS_NONE, filter3);
+ ErrCode filter3 = aMatcher3.DetectFilter(aMedium3, pFilter3);
+ CPPUNIT_ASSERT_EQUAL(ERRCODE_NONE, filter3);
//Filter should be returned with proper Name
CPPUNIT_ASSERT_EQUAL(OUString("writer8"), pFilter3->GetFilterName());
}