Running tests

Aleix Pol aleixpol at kde.org
Thu Jun 2 17:34:08 UTC 2016


Hi,
I'm trying to figure out some issues we're facing in one of the
projects in our runtime. To that end, I wanted to run the unit tests
built by the project.

I've been able to run the tests, but some of them require access to
x11/wayland. Do you know what's the best way to make it available?

That's what I tried: [1]

Thanks in advance!
Aleix

[1]
builder at 5b7f6181fa0a:~/zappdata/xdgapp-runtime$ flatpak build
--nofilesystem=host
--filesystem=/home/builder/zappdata/xdgapp-runtime/.flatpak-builder/build/kparts-1
--bind-mount=/run/build-runtime/kparts=/home/builder/zappdata/xdgapp-runtime/.flatpak-builder/build/kparts-1
--build-dir=/run/build-runtime/kparts
--bind-mount=/run/ccache=/home/builder/zappdata/xdgapp-runtime/.flatpak-builder/ccache
--env=PATH=/run/ccache/bin:/app/bin:/usr/bin
--env=CCACHE_DIR=/run/ccache /home/builder/zappdata/xdgapp-runtime/sdk
ctest .
Test project /run/build-runtime/kparts
    Start 1: parttest
1/2 Test #1: parttest .........................***Exception: Other  0.12 sec
    Start 2: openorsavequestion_unittest
2/2 Test #2: openorsavequestion_unittest ......***Exception: Other  0.09 sec

0% tests passed, 2 tests failed out of 2

Total Test time (real) =   0.21 sec

The following tests FAILED:
          1 - parttest (OTHER_FAULT)
          2 - openorsavequestion_unittest (OTHER_FAULT)
Errors while running CTest
builder at 5b7f6181fa0a:~/zappdata/xdgapp-runtime$ flatpak build
--nofilesystem=host
--filesystem=/home/builder/zappdata/xdgapp-runtime/.flatpak-builder/build/kparts-1
--bind-mount=/run/build-runtime/kparts=/home/builder/zappdata/xdgapp-runtime/.flatpak-builder/build/kparts-1
--build-dir=/run/build-runtime/kparts
--bind-mount=/run/ccache=/home/builder/zappdata/xdgapp-runtime/.flatpak-builder/ccache
--env=PATH=/run/ccache/bin:/app/bin:/usr/bin
--env=CCACHE_DIR=/run/ccache /home/builder/zappdata/xdgapp-runtime/sdk
ctest . -V
UpdateCTestConfiguration  from :/run/build-runtime/kparts/DartConfiguration.tcl
UpdateCTestConfiguration  from :/run/build-runtime/kparts/DartConfiguration.tcl
Test project /run/build-runtime/kparts
Constructing a list of tests
Done constructing a list of tests
Checking test dependency graph...
Checking test dependency graph end
test 1
    Start 1: parttest

1: Test command: /run/build-runtime/kparts/autotests/parttest
1: Test timeout computed to be: 9.99988e+06
1: QXcbConnection: Could not connect to display
1/2 Test #1: parttest .........................***Exception: Other  0.09 sec
test 2
    Start 2: openorsavequestion_unittest

2: Test command: /run/build-runtime/kparts/autotests/openorsavequestion_unittest
2: Test timeout computed to be: 9.99988e+06
2: QXcbConnection: Could not connect to display
2/2 Test #2: openorsavequestion_unittest ......***Exception: Other  0.09 sec

0% tests passed, 2 tests failed out of 2

Total Test time (real) =   0.19 sec

The following tests FAILED:
          1 - parttest (OTHER_FAULT)
          2 - openorsavequestion_unittest (OTHER_FAULT)
Errors while running CTest



More information about the xdg-app mailing list