Comment 34 for bug 156381

Revision history for this message
In , Winfrieddonkers (winfrieddonkers) wrote :

(In reply to comment #23)
> excerpt from workdir/*/JunitTest/sc_unoapi/done.log:
>
> > checking: [sc.ScModelObj::com::sun::star::sheet::XGoalSeek] is iface: [com.sun.star.sheet.XGoalSeek] testcode: [ifc.sheet._XGoalSeek]
> > LOG> Execute: seekGoal()
> > LOG> Goal Result: 16.0 Divergence: 0.0
> > LOG> Goal Result: 9.0 Divergence: 1.7976931348623157E308
> > LOG> Goal Result: 0.8 Divergence: 1.7976931348623157E308
> > Method seekGoal() finished with state FAILED
> > LOG> seekGoal(): PASSED.FAILED

The java test expects tests 1,2 3 to succeed, fail, succeed. The first 2 tests pass, the 3rd doesn't.

The third test going wrong is a special case. The one 'real' root (1) is invalid because of divide by zero, so goal seek must find the an approximate that give an error within the allowable delta (1E-6 in the case of goal seek).
With a start value of 0, goal seek succeeds, but with a start value of 0.8 (the java test) it does not with the patched code and does succeed with unpatched code.
I will try to trace the goal seek process of the patched code to find out what goes wrong.