[Libreoffice-commits] .: sc/qa

Kohei Yoshida kohei at kemper.freedesktop.org
Wed Jun 8 20:40:46 PDT 2011


 sc/qa/unit/ucalc.cxx |    6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

New commits:
commit a9fa8ba99cae6c113270b8559ef57b6a17da33a3
Author: Kohei Yoshida <kyoshida at novell.com>
Date:   Wed Jun 8 23:39:47 2011 -0400

    Let's not use fractional numbers in a string input.
    
    This test fails in locales where the decimal separator is not '.'.

diff --git a/sc/qa/unit/ucalc.cxx b/sc/qa/unit/ucalc.cxx
index 47b812a..e22b6a3 100644
--- a/sc/qa/unit/ucalc.cxx
+++ b/sc/qa/unit/ucalc.cxx
@@ -466,9 +466,9 @@ void Test::testCellFunctions()
         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, 10, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(123)")));
         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, 12, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(\"12\")")));
         m_pDoc->SetString(1, 13, 0, OUString(RTL_CONSTASCII_USTRINGPARAM("=N(\"foo\")")));
 
         // Range references
@@ -481,7 +481,7 @@ void Test::testCellFunctions()
         m_pDoc->CalcAll();
         double checks[] = {
             0, 0,  0,    1, -1, 12.3, 0, // cell reference
-            0, 1, -1, 12.3,  0,    0, 0, // in-line values
+            0, 1, -1, 123,  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