Bug 360899 - ItemViewsPuzzleTest test hangs
Summary: ItemViewsPuzzleTest test hangs
Status: RESOLVED FIXED
Alias: None
Product: bindings
Classification: Developer tools
Component: general (show other bugs)
Version: unspecified
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: kde-bindings
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-03-23 12:12 UTC by Petr Pisar
Modified: 2016-10-03 18:21 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Petr Pisar 2016-03-23 12:12:55 UTC
Running tests perlqt-4.14.3 hangs on ItemViewsPuzzleTest test for me. Running the test manually looks like:

$ xvfb-run -a perl -I/home/test/fedora/perl-Qt/perlqt-4.14.3/build/blib/{arch,lib} "/home/test/fedora/perl-Qt/perlqt-4.14.3/qtgui/t/itemviewspuzzle.t" 
Useless use of left bitshift (<<) in void context at PiecesModel.pm line 117.
1..1
********* Start testing of ItemViewsPuzzleTest *********
Config: Using QTest library 4.8.7, Qt 4.8.7
ok 1 - Window shown
PASS   : ItemViewsPuzzleTest::initTestCase()

Here it hangs, the processor idles then.
Comment 1 Chris Burel 2016-10-03 18:21:05 UTC
Fixed in 8f066267.  The problem is that the itemviews/puzzle example uses the QMessageBox::information() function, which runs its own event loop in its own thread.  The testing framework has no way to detect that this thread has started, so user interaction is required for the test to complete.  My solution is to just monkey patch QMessageBox::information during the test, so that we ensure that it is called when the puzzle is complete, but no additional event loops are created.

http://commits.kde.org/perlqt/8f066267118c66e01d45b60ba086510d577fa854