[Bug 90290] reduce some copy&paste code in ucalc

bugzilla-daemon at bugs.documentfoundation.org bugzilla-daemon at bugs.documentfoundation.org
Sat Apr 11 08:42:33 PDT 2015


https://bugs.documentfoundation.org/show_bug.cgi?id=90290

David Tardon <dtardon at redhat.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |dtardon at redhat.com

--- Comment #13 from David Tardon <dtardon at redhat.com> ---
(In reply to Markus Mohrhard from comment #0)
> ucalc is one of the mail calc tests and is split between many files in
> sc/qa/unit
> 
> This task is about improving the existing pattern around checkFormula in
> sc/qa/unit/ucalc_formula.cxx
> 
> A typical piece of code looks like this:
> 
>     if (!checkFormula(*m_pDoc, aPos, "SUM(A3:A7)"))
>         CPPUNIT_FAIL("Wrong formula!");
> 
> This should be changed to something like:
> 
> checkFormula(*m_pDoc, aPos, "SUM(A3:A7)", "Wrong formula!");

What is wrong with

CPPUNIT_ASSERT_MESSAGE("Wrong formula!", checkFormula(*m_pDoc, aPos,
"SUM(A3:A7)"))

? That would address Kohei's concerns without any necessary changes to cppunit.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/libreoffice/attachments/20150411/464c0dde/attachment.html>


More information about the LibreOffice mailing list