toolkit/qa/cppunit/a11y/XAccessibleComponentTester.cxx |    8 ++++----
 toolkit/qa/cppunit/a11y/XAccessibleContextTester.cxx   |   10 +++++-----
 2 files changed, 9 insertions(+), 9 deletions(-)

New commits:
commit 37ca4d9fa7e63631799fba9e3faf1bfdbb66b11e
Author:     Rene Engelhard <r...@rene-engelhard.de>
AuthorDate: Fri Jun 10 21:35:43 2022 +0200
Commit:     René Engelhard <r...@debian.org>
CommitDate: Sat Jun 11 09:08:31 2022 +0200

    fix 32bit build in new a11y cppunit tests
    
    /<<PKGBUILDDIR>>/toolkit/qa/cppunit/a11y/XAccessibleComponentTester.cxx: In 
member function ‘void XAccessibleComponentTester::testBounds()’:
    
/<<PKGBUILDDIR>>/toolkit/qa/cppunit/a11y/XAccessibleComponentTester.cxx:51:5: 
error: no matching function for call to ‘assertGreaterEqual(int, sal_Int32&, 
CppUnit::SourceLine, const char [1])’
       51 |     CPPUNIT_ASSERT_GREATEREQUAL(0, bounds.X);
          |     ^
    /usr/include/cppunit/TestAssert.h:251:6: note: candidate: ‘template<class 
T> void CppUnit::assertGreaterEqual(const T&, const T&, CppUnit::SourceLine, 
const string&)’
      251 | void assertGreaterEqual( const T& expected,
          |      ^~~~~~~~~~~~~~~~~~
    /usr/include/cppunit/TestAssert.h:251:6: note:   template argument 
deduction/substitution failed:
    
/<<PKGBUILDDIR>>/toolkit/qa/cppunit/a11y/XAccessibleComponentTester.cxx:51:5: 
note:   deduced conflicting types for parameter ‘const T’ (‘int’ and 
‘sal_Int32’ {aka ‘long int’})
       51 |     CPPUNIT_ASSERT_GREATEREQUAL(0, bounds.X);
          |     ^
    
    etc.
    
    Regression from d2a5b4bc0b8c8d1dd82133719a3ef5cc01b0cbbe
    
    Change-Id: I123894e5ed6d6f3bcf46b1c5b37f1f49cb5f9f99
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135630
    Tested-by: Jenkins
    Tested-by: René Engelhard <r...@debian.org>
    Reviewed-by: René Engelhard <r...@debian.org>
    (cherry picked from commit 69c964bbd56ff49324d1ca649739fae354dd4c16)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135634

diff --git a/toolkit/qa/cppunit/a11y/XAccessibleComponentTester.cxx 
b/toolkit/qa/cppunit/a11y/XAccessibleComponentTester.cxx
index 5613724786b9..ea46ff778575 100644
--- a/toolkit/qa/cppunit/a11y/XAccessibleComponentTester.cxx
+++ b/toolkit/qa/cppunit/a11y/XAccessibleComponentTester.cxx
@@ -48,10 +48,10 @@ void XAccessibleComponentTester::testBounds()
     auto bounds = mxComponent->getBounds();
     std::cout << "bounds: " << bounds.Width << "x" << bounds.Height << 
std::showpos << bounds.X
               << bounds.Y << std::noshowpos << std::endl;
-    CPPUNIT_ASSERT_GREATEREQUAL(0, bounds.X);
-    CPPUNIT_ASSERT_GREATEREQUAL(0, bounds.Y);
-    CPPUNIT_ASSERT_GREATER(0, bounds.Width);
-    CPPUNIT_ASSERT_GREATER(0, bounds.Height);
+    CPPUNIT_ASSERT_GREATEREQUAL(static_cast<sal_Int32>(0), bounds.X);
+    CPPUNIT_ASSERT_GREATEREQUAL(static_cast<sal_Int32>(0), bounds.Y);
+    CPPUNIT_ASSERT_GREATER(static_cast<sal_Int32>(0), bounds.Width);
+    CPPUNIT_ASSERT_GREATER(static_cast<sal_Int32>(0), bounds.Height);
 }
 
 /**
diff --git a/toolkit/qa/cppunit/a11y/XAccessibleContextTester.cxx 
b/toolkit/qa/cppunit/a11y/XAccessibleContextTester.cxx
index 3a7eb70e9dd5..b8c7898f963f 100644
--- a/toolkit/qa/cppunit/a11y/XAccessibleContextTester.cxx
+++ b/toolkit/qa/cppunit/a11y/XAccessibleContextTester.cxx
@@ -57,7 +57,7 @@ void XAccessibleContextTester::testGetAccessibleChildCount()
 {
     auto childCount = mxContext->getAccessibleChildCount();
     std::cout << childCount << " children found." << std::endl;
-    CPPUNIT_ASSERT_GREATEREQUAL(0, childCount);
+    CPPUNIT_ASSERT_GREATEREQUAL(static_cast<sal_Int32>(0), childCount);
 }
 
 /**
@@ -130,10 +130,10 @@ void 
XAccessibleContextTester::testGetAccessibleRelationSet()
  */
 void XAccessibleContextTester::testGetAccessibleRole()
 {
-    sal_Int16 role = mxContext->getAccessibleRole();
+    sal_Int32 role = mxContext->getAccessibleRole();
     std::cout << "The role is " << role << " (" << 
AccessibilityTools::getRoleName(role) << ")"
               << std::endl;
-    CPPUNIT_ASSERT_GREATEREQUAL(static_cast<sal_Int16>(0), role);
+    CPPUNIT_ASSERT_GREATEREQUAL(static_cast<sal_Int32>(0), role);
 }
 
 /**
@@ -157,8 +157,8 @@ void XAccessibleContextTester::testGetLocale()
 {
     auto loc = mxContext->getLocale();
     std::cout << "The locale is " << loc.Language << "," << loc.Country << 
std::endl;
-    CPPUNIT_ASSERT_GREATER(0, loc.Language.getLength());
-    CPPUNIT_ASSERT_GREATER(0, loc.Country.getLength());
+    CPPUNIT_ASSERT_GREATER(static_cast<sal_Int32>(0), 
loc.Language.getLength());
+    CPPUNIT_ASSERT_GREATER(static_cast<sal_Int32>(0), loc.Country.getLength());
 }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s 
cinkeys+=0=break: */

Reply via email to