A first part of the layers/masks patch

Dmitry Kazakov dimula73 at gmail.com
Sun Sep 27 16:10:46 CEST 2009


On Sun, Sep 27, 2009 at 2:20 PM, Boudewijn Rempt <boud at valdyas.org> wrote:

> On Sunday 27 September 2009, Boudewijn Rempt wrote:
> > Btw, if the unittests pass, please commit your patches. I think everyone
> > agrees on that now.
> >
>
> I've applied the patch now by hacking out the conflicts and the only test I
> see failing is KisPaintLayerTest on the transparency mask, which is fixed
> by
> not inverting the mask.
>

What have you fixed? OPACITY_TRANSPARENT to OPACITY_OPAQUE? Right?


About the other comments in the paint layer test:
>
>    /**
>     * FIXME: Needs approval by someone else
>     * This is quite insane demands as a projection is still no way updated.
>     * There is no difference for us whether layer->projection() is equal
>     * to layer->paintDevice() or is equal to NULL, isn't it?
>     */
>    // Which also means that the projection is no longer the paint device
>    //QVERIFY(layer->paintDevice().data() != layer->projection().data());
>
>
> This is a check that as soon as we add masks, there is a projection. Not
> whether the projection has been updated or now. Now, if the projection is
> only
> created during the recomposition process in the new situation this test
> doesn't hold.
>

Does it mean, that i can remove those lines?


>
> You have to understand the basic nature of a unittest: it tests the
> expected
> behaviour of a class. If you change that behaviour, you have to change the
> test accordingly, but not just comment out tests. We have to be certain
> that
> this class is well behaved.
>

=) As i understand tests' purpose is to fix "interface" of the classes :)
And not to check it's internals =)


-- 
Dmitry Kazakov
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.kde.org/pipermail/kimageshop/attachments/20090927/f088a939/attachment.htm 


More information about the kimageshop mailing list