Test failing - CppunitTest_cppcanvas_emfplus

Jan-Marek Glogowski glogow at fbihome.de
Mon Feb 16 00:30:40 PST 2015


Am 16.02.2015 um 03:47 schrieb Chris Sherlock:
> I guess it would also be helpful to note:
> 
> When I open it in oletoy, it's very definitely meant to be #00ff00 (green). There is some anti-aliasing, but that's not at position (140, 142)... and actually (140, 140) is the same as (140, 142). 
> 
> Chris
> 
>> On 16 Feb 2015, at 1:38 pm, Chris Sherlock <chris.sherlock79 at gmail.com> wrote:
>>
>> Hey all, 
>>
>> It appears that we are exporting an EMF+ file to PNG, then we do a check to see what color a particular pixel is. 
>>
>> It *looks* like the actual result should actually be 65280 (0x00FF00 or green), but for some reason we are checking if it’s 65024 (0x00FE00 or a slightly lighter shade of green). 
>>
>> This test is for the bug here:
>>
>> https://bugs.documentfoundation.org/show_bug.cgi?id=77229
>>
>> Can anyone shed any light on this? I think the test is wrong, but would like some other eyes on the code. Thanks!
>>
>> warn:vcl.window:31765:1:vcl/source/window/window.cxx:3329: ignoring DeploymentException "service not supplied"
>> warn:sfx.sidebar:31765:1:sfx2/source/sidebar/SidebarController.cxx:764: Cannot create panel: 
>> /home/chris/repos/libreoffice/cppcanvas/qa/extras/emfplus/emfplus.cxx:89:Test::testFdo77229
>> equality assertion failed
>> - Expected: 65024
>> - Actual  : 65280
>>

...

Yeah - that's a known problem.

>From my TinderBox start script:

> # Start virtual X
> # Needs to be 24 bit, otherwise emf tests fail
> Xvfb :3 -screen 0 1280x1024x24 &
> X_PID=$!
> export DISPLAY=:3

I had a quick look some time ago and tried to find a way to get the
actual color depth from system settings or VCL; obviously didn't find it.

The fix would be quite easy: if you're able to access the BPP settings
simply skip the test.

Is there actually a CppUnit-Macro to "actively" skip tests?

Same problem exists for Windows ADO tests - well actually we have to
abort the tests, if some part of the setup fails, i.e skip the tests, if
COM initialization fails and not just ignore the result values. An even
more simple patch...

JMG



More information about the LibreOffice mailing list