diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-02-01 09:26:27 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-02-02 08:00:10 +0000 |
commit | 1461ebbbb5d47d90e31f0945a4878a68fbee5213 (patch) | |
tree | 5af28d3cdaf4d5195ddf9e69727807ab8104a8e2 /sax/qa | |
parent | c0f9bdd3e644e3ebf690aff9eb1aeec4f16dbf27 (diff) |
expand out ::sax::Converter::convertNumber to OUString::number
which results in much simpler code overall, there is no need to go via
an OUStringBuffer all the time
Change-Id: I69eba92c93f471fa9a45f97c29c56dcf3cd1ebf8
Reviewed-on: https://gerrit.libreoffice.org/33773
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sax/qa')
-rw-r--r-- | sax/qa/cppunit/test_converter.cxx | 14 |
1 files changed, 0 insertions, 14 deletions
diff --git a/sax/qa/cppunit/test_converter.cxx b/sax/qa/cppunit/test_converter.cxx index c8b813c47d22..6a1f087e143a 100644 --- a/sax/qa/cppunit/test_converter.cxx +++ b/sax/qa/cppunit/test_converter.cxx @@ -610,15 +610,6 @@ void doTestStringToNumber(sal_Int32 nValue, char const*const pis, sal_Int32 nMin CPPUNIT_ASSERT_EQUAL(nValue, nTemp); } -void doTestNumberToString(char const*const pis, sal_Int32 nValue) -{ - OUString const is(OUString::createFromAscii(pis)); - OUStringBuffer buf; - Converter::convertNumber(buf, nValue); - SAL_INFO("sax.cppunit","" << buf.toString()); - CPPUNIT_ASSERT_EQUAL(is, buf.makeStringAndClear()); -} - void ConverterTest::testNumber() { doTestStringToNumber(30, "30", 1, 40); @@ -626,11 +617,6 @@ void ConverterTest::testNumber() doTestStringToNumber(-30, "7", -100, -30); doTestStringToNumber(0, "-0", 0, 1); doTestStringToNumber(0, "666", -0, 0); - doTestNumberToString("333", 333); - doTestNumberToString("-1", -1); - doTestNumberToString("0", 0000); - doTestNumberToString("-1", -0001); - doTestNumberToString("0", -0); } void doTestEncodeBase64(char const*const pis, const uno::Sequence<sal_Int8>& aPass) |