Dolphin regressions in KDE 4.9.4

Frank Reininghaus frank78ac at googlemail.com
Sat Dec 8 14:37:40 GMT 2012


Hi David,

2012/12/8 David Faure:
> On Saturday 08 December 2012 00:07:38 Frank Reininghaus wrote:
>>  At least the two Dolphin issues should be easily unit-testable
>> - I'll make sure that these tests are in place before any further
>> non-trivial changes in these areas (which have already been subject to
>> regressions earlier) are made.
>
> Unit-testing drag-n-drop is pretty hard. At least, it's impossible (AFAIK) to
> emulate an actual dnd, so the next best thing is to just extract the
> "preparing the QMimeData" code (without the QDrag::exec), and calling that,
> and then calling the drop code directly (without a QDropEvent as input)...

Yes, exactly. Anything that uses nested event loops is probably very
hard to unit-test. That is not the only reason why I dislike nested
event loops, BTW ;-)

But mostly the same code in DolphinView (including the place where the
random crashes happened) can actually be triggered by pasting items.
We did have unit tests for that in the 4.7 branch, but they haven't
been ported to Dolphin 2.0 yet. Actually, these tests also call
DolphinView's functions directly, rather than simulating a real
invocation of the "Paste" action, should be easy to extend that to
also cover drops. I'll work on porting those tests.

Best regards,
Frank




More information about the kfm-devel mailing list