[Libreoffice-commits] .: sc/qa

Kohei Yoshida kohei at kemper.freedesktop.org
Wed Jun 8 20:23:41 PDT 2011


 sc/qa/unit/ucalc.cxx |   38 ++++++++++++++++----------------------
 1 file changed, 16 insertions(+), 22 deletions(-)

New commits:
commit 7f08436d702a23e8d32b6a73c1a8a580166248cf
Author: Kohei Yoshida <kyoshida at novell.com>
Date:   Wed Jun 8 23:22:54 2011 -0400

    Skip the tests for boolean values.  They don't pass in non en-US locales.

diff --git a/sc/qa/unit/ucalc.cxx b/sc/qa/unit/ucalc.cxx
index fe75b0f..47b812a 100644
--- a/sc/qa/unit/ucalc.cxx
+++ b/sc/qa/unit/ucalc.cxx
@@ -451,9 +451,7 @@ void Test::testCellFunctions()
         m_pDoc->SetValue(0, 4, 0, val);
         val = 12.3;
         m_pDoc->SetValue(0, 5, 0, val);
-        m_pDoc->SetString(0, 6, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("TRUE")));
-        m_pDoc->SetString(0, 7, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("FALSE")));
-        m_pDoc->SetString(0, 8, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("'12.3")));
+        m_pDoc->SetString(0, 6, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("'12.3")));
 
         // Cell references
         m_pDoc->SetString(1, 0, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(A1)")));
@@ -462,33 +460,29 @@ void Test::testCellFunctions()
         m_pDoc->SetString(1, 3, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(A4)")));
         m_pDoc->SetString(1, 4, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(A5)")));
         m_pDoc->SetString(1, 5, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(A6)")));
-        m_pDoc->SetString(1, 6, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(A7)")));
-        m_pDoc->SetString(1, 7, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(A8)")));
-        m_pDoc->SetString(1, 8, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(A9)")));
+        m_pDoc->SetString(1, 6, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(A9)")));
 
         // In-line values
-        m_pDoc->SetString(1, 9, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(0)")));
-        m_pDoc->SetString(1, 10, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(1)")));
-        m_pDoc->SetString(1, 11, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(-1)")));
-        m_pDoc->SetString(1, 12, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(12.3)")));
-        m_pDoc->SetString(1, 13, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(TRUE)")));
-        m_pDoc->SetString(1, 14, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(FALSE)")));
-        m_pDoc->SetString(1, 15, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(\"\")")));
-        m_pDoc->SetString(1, 16, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(\"1.2\")")));
-        m_pDoc->SetString(1, 17, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(\"foo\")")));
+        m_pDoc->SetString(1, 7, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(0)")));
+        m_pDoc->SetString(1, 8, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(1)")));
+        m_pDoc->SetString(1, 9, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(-1)")));
+        m_pDoc->SetString(1, 10, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(12.3)")));
+        m_pDoc->SetString(1, 11, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(\"\")")));
+        m_pDoc->SetString(1, 12, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(\"1.2\")")));
+        m_pDoc->SetString(1, 13, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(\"foo\")")));
 
         // Range references
-        m_pDoc->SetString(1, 18, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(A1:A8)")));
-        m_pDoc->SetString(1, 19, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(A4:B8)")));
-        m_pDoc->SetString(1, 20, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(A6:B8)")));
-        m_pDoc->SetString(1, 21, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(A2:B8)")));
+        m_pDoc->SetString(1, 14, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(A1:A8)")));
+        m_pDoc->SetString(1, 15, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(A4:B8)")));
+        m_pDoc->SetString(1, 16, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(A6:B8)")));
+        m_pDoc->SetString(1, 17, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(A2:B8)")));
 
         // Calculate and check the results.
         m_pDoc->CalcAll();
         double checks[] = {
-            0, 0,  0,    1, -1, 12.3, 1, 0, 0, // cell reference
-            0, 1, -1, 12.3,  1,    0, 0, 0, 0, // in-line values
-            0, 1, 12.3, 0
+            0, 0,  0,    1, -1, 12.3, 0, // cell reference
+            0, 1, -1, 12.3,  0,    0, 0, // in-line values
+            0, 1, 12.3, 0                // range references
         };
         for (size_t i = 0; i < SAL_N_ELEMENTS(checks); ++i)
         {


More information about the Libreoffice-commits mailing list