[gjs: 2/4] CI: run the 'installed tests' only if requested



commit a3bb9ce8ad3c98594e2dfc2be3e0d25fa29c3508
Author: Claudio André <claudioandre br gmail com>
Date:   Thu Nov 2 18:05:29 2017 -0200

    CI: run the 'installed tests' only if requested
    
    So, it can be run, e.g., only on master.

 .gitlab-ci.yml  | 10 +++++++++-
 test/test-ci.sh |  7 +++++--
 2 files changed, 14 insertions(+), 3 deletions(-)
---
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index fee807c..adc3392 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -24,7 +24,7 @@ before_script:
          rm -rf /hoard/SAVED;
        fi'
 
-    # Build and test GJS
+    # Build dependencies and 'make check' gjs
     - 'if [[ -d "/hoard/SAVED/$OS/jhbuild" ]]; then
          $(pwd)/test/test-ci.sh GET_FILES;
        else
@@ -32,6 +32,11 @@ before_script:
        fi'
     - $(pwd)/test/test-ci.sh GJS
 
+    # Extra testing
+    - 'if [[ $BUILD_OPTS == *"--enable-installed-tests"* ]]; then
+         $(pwd)/test/test-ci.sh GJS_EXTRA;
+       fi'
+
 ubuntu_gcc:
   <<: *build
   image: ubuntu:rolling
@@ -39,6 +44,9 @@ ubuntu_gcc:
     BASE: ubuntu
     OS: ubuntu:rolling
     CC: gcc
+    BUILD_OPTS: "--enable-installed-tests"
+  only:
+    - master@GNOME/gjs
 
 fedora_gcc:
   <<: *build
diff --git a/test/test-ci.sh b/test/test-ci.sh
index 58947a2..4130f84 100755
--- a/test/test-ci.sh
+++ b/test/test-ci.sh
@@ -126,7 +126,7 @@ function do_Configure_JHBuild(){
     echo '-- Set JHBuild Configuration --'
 
     mkdir -p ~/.config
-    autogenargs="--enable-compile-warnings=error --enable-installed-tests --with-xvfb-tests"
+    autogenargs="--enable-compile-warnings=error --with-xvfb-tests"
 
     if [[ -n "${BUILD_OPTS}" ]]; then
         autogenargs="$autogenargs $BUILD_OPTS"
@@ -263,9 +263,12 @@ elif [[ $1 == "GJS" ]]; then
     echo
     jhbuild make --check
 
-    # Extra testing
+elif [[ $1 == "GJS_EXTRA" ]]; then
+    # Extra testing. It doesn't build, just run the 'Installed Tests'
     echo
     echo '-- Installed GJS tests --'
+    do_Set_Env
+    PATH=$PATH:~/.local/bin
     xvfb-run jhbuild run dbus-run-session -- gnome-desktop-testing-runner gjs
 
 else


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]