kImageAnnotator
kImageAnnotator copied to clipboard
KeyInputHelperTest failed with QT_QPA_PLATFORM=offscreen
Hi!
We packages KImageAnnotator for Gentoo Linux and have 1 test faild when setting QT_QPA_PLATFORM=offscreen
23/49 Test: KeyInputHelperTest
Command: "/var/tmp/portage/media-libs/kimageannotator-0.7.0/work/kImageAnnotator-0.7.0_build/tests/KeyInputHelperTest"
Directory: /var/tmp/portage/media-libs/kimageannotator-0.7.0/work/kImageAnnotator-0.7.0_build/tests
"KeyInputHelperTest" start time: Feb 27 22:51 MSK
Output:
----------------------------------------------------------
********* Start testing of KeyInputHelperTest *********
Config: Using QtTest library 6.6.2, Qt 6.6.2 (x86_64-little_endian-lp64 shared (dynamic) release build; by GCC 13.2.1 20240210), gentoo 2.14
PASS : KeyInputHelperTest::initTestCase()
PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitRemoveSignal_When_KeyIsBackspace()
PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitRemoveSignal_When_KeyIsDelete()
PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitInsertSignalWithNewLine_When_KeyIsReturnAndModifierShift()
PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitInsertSignalWithNewLine_When_KeyIsEnterAndModifierShift()
PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitEscape_When_KeyIsReturnAndNoModifier()
PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitEscape_When_KeyIsEnterAndNoModifier()
PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitEscapeSignal_When_KeyIsEscape()
PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitMoveSignal_When_KeyIsHome()
PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitMoveSignal_When_KeyIsEnd()
PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitMoveSignal_When_KeyIsArrowLeft()
PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitMoveSignal_When_KeyIsArrowLeftAndModifierCtrl()
PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitMoveSignal_When_KeyIsArrowRight()
PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitMoveSignal_When_KeyIsArrowRightAndModifierCtrl()
PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitMoveSignal_When_KeyIsArrowUp()
PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitMoveSignal_When_KeyIsArrowDown()
PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitPasteSignal_When_KeyIsPaste()
PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitPasteSignal_When_KeySequenceIsPaste()
Received signal 11 (SIGSEGV), code 1, for address 0x00000000000000f8
TestHandleKeyPress_Should_EmitInsertSignal_When_KeyIsCharacter function time: 0ms, total time: 0ms
<end of output>
Test time = 0.14 sec
----------------------------------------------------------
Test Failed.
"KeyInputHelperTest" end time: Feb 27 22:51 MSK
"KeyInputHelperTest" time elapsed: 00:00:00
----------------------------------------------------------
I cannot reproduce this issue with latest 0.7.0. What Qt version are you using?
@alexxy I assume you ran the unit tests against Qt6? Could you post your build env?
I have built up an environment, and gotten the fail captured with stack trace
********* Start testing of KeyInputHelperTest ********* Config: Using QtTest library 6.6.2, Qt 6.6.2 (x86_64-little_endian-lp64 shared (dynamic) release build; by GCC 13.2.1 20240113), gentoo 2.14 PASS : KeyInputHelperTest::initTestCase() PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitRemoveSignal_When_KeyIsBackspace() PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitRemoveSignal_When_KeyIsDelete() PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitInsertSignalWithNewLine_When_KeyIsReturnAndModifierShift() PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitInsertSignalWithNewLine_When_KeyIsEnterAndModifierShift() PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitEscape_When_KeyIsReturnAndNoModifier() PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitEscape_When_KeyIsEnterAndNoModifier() PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitEscapeSignal_When_KeyIsEscape() PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitMoveSignal_When_KeyIsHome() PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitMoveSignal_When_KeyIsEnd() PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitMoveSignal_When_KeyIsArrowLeft() PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitMoveSignal_When_KeyIsArrowLeftAndModifierCtrl() PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitMoveSignal_When_KeyIsArrowRight() PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitMoveSignal_When_KeyIsArrowRightAndModifierCtrl() PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitMoveSignal_When_KeyIsArrowUp() PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitMoveSignal_When_KeyIsArrowDown() PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitPasteSignal_When_KeyIsPaste() PASS : KeyInputHelperTest::TestHandleKeyPress_Should_EmitPasteSignal_When_KeySequenceIsPaste() Received signal 11 (SIGSEGV), code 1, for address 0x00000000000000f8 TestHandleKeyPress_Should_EmitInsertSignal_When_KeyIsCharacter function time: 0ms, total time: 0ms
=== Stack trace === [New LWP 3016] [Thread debugging using libthread_db enabled] Using host libthread_db library "/lib64/libthread_db.so.1". 0x00007f2ade0fef77 in wait4 () from /lib64/libc.so.6
Thread 2 (Thread 0x7f2adb0b46c0 (LWP 3016) "QtTest Watchdog"):
#0 0x00007f2ade09fc8e in __futex_abstimed_wait_common () from /lib64/libc.so.6
#1 0x00007f2ade0a2a84 in pthread_cond_clockwait () from /lib64/libc.so.6
#2 0x00007f2adfb6a70d in std::__condvar::wait_until (__abs_time=..., __clock=1, __m=..., this=
Thread 1 (Thread 0x7f2adb3fc340 (LWP 3015) "KeyInputHelperT"):
#0 0x00007f2ade0fef77 in wait4 () from /lib64/libc.so.6
#1 0x00007f2adfb5f195 in generateStackTrace () at /usr/src/debug/dev-qt/qtbase-6.6.2/qtbase-everywhere-src-6.6.2/src/testlib/qtestcase.cpp:411
#2 0x00007f2adfb60f50 in generateStackTrace () at /usr/src/debug/dev-qt/qtbase-6.6.2/qtbase-everywhere-src-6.6.2/src/testlib/qtestcase.cpp:375
#3 (anonymous namespace)::FatalSignalHandler::actionHandler (signum=11, info=