summaryrefslogtreecommitdiff
path: root/.gitlab-ci.yml
diff options
context:
space:
mode:
authorPeter Hutterer <peter.hutterer@who-t.net>2019-10-29 16:58:22 +1000
committerPeter Hutterer <peter.hutterer@who-t.net>2019-11-15 06:53:41 +1000
commit2adf7bee194b28ad6628ce9b50a4fe8388316956 (patch)
treead66ee93117f170a190ec5a422921f94f0838c74 /.gitlab-ci.yml
parent5c39aeceaa95b8dd5bfc1ffcb9782461c9defb49 (diff)
downloadxkeyboard-config-2adf7bee194b28ad6628ce9b50a4fe8388316956.tar.gz
gitlab CI: run the libxkbcommon xkeyboard-config test tool
This should detect syntax errors and any other parsing issues. We add a make install stage and pass the installed files through as artifacts to the next stage. Then we fetch libxkbcommon from git and run the magic tester tool (which tries to parse every layout/variant/option combination). A single test run will take quite a while, on my system here that tool takes about 14 minutes so expect the test suite to be the same. Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Diffstat (limited to '.gitlab-ci.yml')
-rw-r--r--.gitlab-ci.yml39
1 files changed, 39 insertions, 0 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 36e2f27..1b1f780 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -32,6 +32,20 @@ make:
extends: .default_build
stage: build
+make_install:
+ extends: .default_build
+ stage: build
+ variables:
+ MAKE_EXTRA_COMMAND: "install"
+ after_script:
+ - pacman -S --noconfirm tree
+ - tree $INSTDIR
+ artifacts:
+ name: installed files
+ expire_in: 20 min
+ paths:
+ - $INSTDIR/
+
make_check:
extends: .default_build
stage: build
@@ -43,3 +57,28 @@ make_distcheck:
stage: build
variables:
MAKE_EXTRA_COMMAND: "distcheck"
+
+# download libxkbcommon and run its layout test program. This will
+# run a basic keymap compile test against every combination of
+# layout/variant/option. Syntax errors will fail the test, check the
+# archived file for details.
+layout_tests:
+ extends: .default_setup
+ stage: test
+ needs: ["make_install"]
+ script:
+ - pacman -S --noconfirm git meson bison gcc
+ - git clone https://github.com/xkbcommon/libxkbcommon
+ - pushd libxkbcommon > /dev/null
+ - meson builddir -Denable-wayland=false -Denable-x11=false -Denable-docs=false -Dxkb-config-root="$INSTDIR/share/X11/xkb"
+ - ninja -C builddir
+ - echo Running test script - this will take several minutes
+ - ./builddir/xkeyboard-config-test > $INSTDIR/xkeyboard-config-test.out
+ - popd > /dev/null
+ variables:
+ GIT_STRATEGY: none
+ artifacts:
+ name: xkeyboard-config test output
+ expire_in: 2 weeks
+ paths:
+ - $INSTDIR/xkeyboard-config-test.out