summaryrefslogtreecommitdiff
path: root/cppu
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2023-03-21 23:16:35 +0100
committerStephan Bergmann <sbergman@redhat.com>2023-03-22 08:46:35 +0000
commit9111536f1bbaed489ed3ed36315e05d4b3940f5b (patch)
treec0243c00d14d7ee8439a76f5982d92f74ef87631 /cppu
parent464a3549ae228bcd70bae8ea519fc781c2cc9e45 (diff)
Introduce css.reflection.Dump singleton
...and revert e1c6f36d8bcc0799281e3a7e244175f682d97cb2 "Add a to_string() function to the code generated for UNO IDL constant groups". (But keep the constants groups the latter had added to cppu/qa/cppumaker/types.idl, and use them in the newly added CppunitTest_stoc_dump, for better or worse.) Change-Id: I56e9eaeb1e45b83a72a25eceef13e719dc6f3a1e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/149281 Reviewed-by: Tor Lillqvist <tml@collabora.com> Tested-by: Jenkins
Diffstat (limited to 'cppu')
-rw-r--r--cppu/qa/cppumaker/test_cppumaker.cxx32
1 files changed, 0 insertions, 32 deletions
diff --git a/cppu/qa/cppumaker/test_cppumaker.cxx b/cppu/qa/cppumaker/test_cppumaker.cxx
index cec02d3c710e..a6d3e4942f06 100644
--- a/cppu/qa/cppumaker/test_cppumaker.cxx
+++ b/cppu/qa/cppumaker/test_cppumaker.cxx
@@ -352,9 +352,6 @@
#include <test/codemaker/cppumaker/TestException1.hpp>
#include <test/codemaker/cppumaker/TestException2.hpp>
#include <test/codemaker/cppumaker/Constants.hpp>
-#include <test/codemaker/cppumaker/ByteBits.hpp>
-#include <test/codemaker/cppumaker/ShortBits.hpp>
-#include <test/codemaker/cppumaker/UnsignedHyperBits.hpp>
#include <memory>
#include <com/sun/star/uno/Any.hxx>
@@ -393,14 +390,11 @@ public:
void testConstants();
- void testSymbolicConstants();
-
CPPUNIT_TEST_SUITE(Test);
CPPUNIT_TEST(testBigStruct);
CPPUNIT_TEST(testPolyStruct);
CPPUNIT_TEST(testExceptions);
CPPUNIT_TEST(testConstants);
- CPPUNIT_TEST(testSymbolicConstants);
CPPUNIT_TEST_SUITE_END();
};
@@ -556,32 +550,6 @@ void Test::testConstants() {
test::codemaker::cppumaker::Constants::unsignedHyperMax);
}
-void Test::testSymbolicConstants() {
- CPPUNIT_ASSERT_EQUAL(OUString("byteMin"), test::codemaker::cppumaker::Constants::to_string(static_cast<sal_uInt64>(-128)));
- CPPUNIT_ASSERT_EQUAL(OUString("byteMax"), test::codemaker::cppumaker::Constants::to_string(127));
- CPPUNIT_ASSERT_EQUAL(OUString("longMin"), test::codemaker::cppumaker::Constants::to_string(static_cast<sal_uInt64>(-2147483648)));
- CPPUNIT_ASSERT_EQUAL(OUString("longMax"), test::codemaker::cppumaker::Constants::to_string(2147483647));
- CPPUNIT_ASSERT_EQUAL(OUString("hyperMin"), test::codemaker::cppumaker::Constants::to_string(static_cast<sal_uInt64>(SAL_MIN_INT64)));
- CPPUNIT_ASSERT_EQUAL(OUString("hyperMax"), test::codemaker::cppumaker::Constants::to_string(SAL_MAX_INT64));
- CPPUNIT_ASSERT_EQUAL(OUString("17"), test::codemaker::cppumaker::Constants::to_string(17));
- CPPUNIT_ASSERT_EQUAL(OUString("2147483646"), test::codemaker::cppumaker::Constants::to_string(2147483646));
-
- CPPUNIT_ASSERT_EQUAL(OUString("0"), test::codemaker::cppumaker::ByteBits::to_string(0));
- CPPUNIT_ASSERT_EQUAL(OUString("BIT0+BIT2"), test::codemaker::cppumaker::ByteBits::to_string(5));
- CPPUNIT_ASSERT_EQUAL(OUString("BIT4"), test::codemaker::cppumaker::ByteBits::to_string(16));
- CPPUNIT_ASSERT_EQUAL(OUString("BIT0+BIT4"), test::codemaker::cppumaker::ByteBits::to_string(17));
- CPPUNIT_ASSERT_EQUAL(OUString("BIT7"), test::codemaker::cppumaker::ByteBits::to_string(-128));
- CPPUNIT_ASSERT_EQUAL(OUString("ALL"), test::codemaker::cppumaker::ByteBits::to_string(-1));
-
- CPPUNIT_ASSERT_EQUAL(OUString("BIT7"), test::codemaker::cppumaker::ShortBits::to_string(128));
- CPPUNIT_ASSERT_EQUAL(OUString("ALL"), test::codemaker::cppumaker::ShortBits::to_string(-1));
-
- CPPUNIT_ASSERT_EQUAL(OUString("BIT63"), test::codemaker::cppumaker::UnsignedHyperBits::to_string(9223372036854775808u));
- CPPUNIT_ASSERT_EQUAL(OUString("BIT0+BIT62"), test::codemaker::cppumaker::UnsignedHyperBits::to_string(4611686018427387905));
- CPPUNIT_ASSERT_EQUAL(OUString("BIT0+BIT63"), test::codemaker::cppumaker::UnsignedHyperBits::to_string(9223372036854775809u));
- CPPUNIT_ASSERT_EQUAL(OUString("ALL"), test::codemaker::cppumaker::UnsignedHyperBits::to_string(SAL_MAX_UINT64));
-}
-
CPPUNIT_TEST_SUITE_REGISTRATION(Test);
}