You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by jo...@apache.org on 2020/03/23 12:08:02 UTC

svn commit: r1875540 - /httpd/httpd/trunk/.travis.yml

Author: jorton
Date: Mon Mar 23 12:08:01 2020
New Revision: 1875540

URL: http://svn.apache.org/viewvc?rev=1875540&view=rev
Log:
Better define conditions for skipping tests on 2.4.x or non-2.4.x.
Use YAML anchors and references to avoid copy&pasting, hopefully 
the syntax remains reasonably readable.

Modified:
    httpd/httpd/trunk/.travis.yml

Modified: httpd/httpd/trunk/.travis.yml
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/.travis.yml?rev=1875540&r1=1875539&r2=1875540&view=diff
==============================================================================
--- httpd/httpd/trunk/.travis.yml (original)
+++ httpd/httpd/trunk/.travis.yml Mon Mar 23 12:08:01 2020
@@ -30,6 +30,13 @@ env:
   global:
     - MFLAGS=-j2
 
+# This defines two condition anchors which can be used in job
+# definitions to either:
+#  condition_24x_only => run the job only for 2.4.x
+#  condition_not_24x  => run the job everywhere EXCEPT 2.4.x
+_cond1: &condition_24x_only (branch is present AND branch = 2.4.x) OR (tag is present AND tag ~= /^2.4/)
+_cond2: &condition_not_24x (branch is present AND branch != 2.4.x) OR (tag is present AND tag !~ /^2.4/)
+
 jobs:
   include:
     - name: Linux Ubuntu, Default module set
@@ -98,7 +105,7 @@ jobs:
       env: CONFIG="--enable-mods-shared=reallyall --enable-maintainer-mode NOTEST_CFLAGS=-Werror CC=gcc-7"
            SKIP_TESTING=1
     # -------------------------------------------------------------------------
-    - if: branch = trunk
+    - if: *condition_not_24x
       name: Linux Ubuntu, PCRE 1, GCC 7 maintainer-mode w/-Werror
       os: linux
       env: CONFIG="--enable-mods-shared=reallyall --with-pcre=/usr/bin/pcre-config --enable-maintainer-mode NOTEST_CFLAGS=-Werror CC=gcc-7"
@@ -144,19 +151,19 @@ jobs:
             - libpcre2-dev
     # -------------------------------------------------------------------------
     # MFLAGS= works around https://bz.apache.org/bugzilla/show_bug.cgi?id=63942
-    - if: branch = trunk
+    - if: *condition_not_24x
       name: Linux Ubuntu, Regenerate ap_expr
       os: linux
       env: CONFIG="--enable-mods-shared=reallyall --enable-maintainer-mode NOTEST_CFLAGS=-Werror"
            BUILDCONFIG="--with-regen-expr"
            MFLAGS=
     # -------------------------------------------------------------------------
-    - if: branch = trunk
+    - if: *condition_not_24x
       name: Linux Ubuntu, APR trunk
       env: APR_VERSION=trunk APR_CONFIG="--with-crypto"
            CONFIG="--enable-mods-shared=reallyall"
     # -------------------------------------------------------------------------
-    - if: branch = 2.4.x or tag =~ /^2.4/
+    - if: *condition_24x_only
       name: Linux Ubuntu Xenial, all-modules, system APR/APR-util
       os: linux
       dist: xenial
@@ -208,17 +215,17 @@ jobs:
             - libpcre2-dev
             - litmus
     # -------------------------------------------------------------------------
-    - if: branch = 2.4.x or tag =~ /^2.4/
+    - if: *condition_24x_only
       name: Linux Ubuntu, APR 1.5.1, APR-util 1.5.4
       env: APR_VERSION=1.5.1 APU_VERSION=1.5.4
            CONFIG="--enable-mods-shared=reallyall"
     # -------------------------------------------------------------------------
-    - if: branch = 2.4.x or tag =~ /^2.4/
+    - if: *condition_24x_only
       name: Linux Ubuntu, APR 1.4.8, APR-util 1.4.2
       env: APR_VERSION=1.4.8 APU_VERSION=1.4.2
            CONFIG="--enable-mods-shared=reallyall"
     # -------------------------------------------------------------------------
-    - if: branch = trunk
+    - if: *condition_not_24x
       name: Linux Ubuntu, UBSan
       env: NOTEST_CFLAGS="-fsanitize=undefined -fno-sanitize-recover=undefined" NOTEST_LIBS=-lubsan
            CONFIG="--enable-mods-shared=reallyall --disable-http2" TEST_UBSAN=1