]> git.ipfire.org Git - thirdparty/strongswan.git/commitdiff
appveyor: Run tests on AppVeyor Windows containers
authorTobias Brunner <tobias@strongswan.org>
Wed, 19 Jul 2017 10:34:35 +0000 (12:34 +0200)
committerTobias Brunner <tobias@strongswan.org>
Fri, 28 Jul 2017 09:18:17 +0000 (11:18 +0200)
We can't enable leak detective as it is so slow then that we run into a
timeout (60 minutes).

.appveyor.yml [new file with mode: 0644]
scripts/test.sh

diff --git a/.appveyor.yml b/.appveyor.yml
new file mode 100644 (file)
index 0000000..941f4c2
--- /dev/null
@@ -0,0 +1,25 @@
+clone_depth: 50
+
+environment:
+  global:
+    TESTS_REDUCED_KEYLENGTHS: yes
+    LEAK_DETECTIVE: no
+    MONOLITHIC: yes
+    TZ: Europe/Zurich
+  matrix:
+    - arch: x86_64
+      bits: 64
+    # no 32-bit build as 32-bit msys is not installed
+    #- arch: i686
+    #  bits: 32
+
+install:
+  - set MSYS_SH=C:\msys%BITS%\usr\bin\sh.exe
+  - set MSYSTEM=MINGW%BITS%
+  - set TEST=win%BITS%
+
+build_script:
+  - '%MSYS_SH% --login -c ". /etc/profile && cd $APPVEYOR_BUILD_FOLDER && ./scripts/test.sh deps"'
+
+test_script:
+  - '%MSYS_SH% --login -c ". /etc/profile && cd $APPVEYOR_BUILD_FOLDER && ./scripts/test.sh"'
index 22e74033e276388545aeafbe7c941ea30fe72de9..238102f320cdc406bf4aee8be754d491a1f9df89 100755 (executable)
@@ -64,8 +64,10 @@ win*)
                        --enable-tnccs-20 --enable-imc-attestation --enable-imv-attestation
                        --enable-imc-os --enable-imv-os --enable-tnc-imv --enable-tnc-imc
                        --enable-pki --enable-swanctl --enable-socket-win"
-       # no make check for Windows binaries
-       TARGET=
+       # no make check for Windows binaries unless we run on a windows host
+       if test "$APPVEYOR" != "True"; then
+               TARGET=
+       fi
        CFLAGS="$CFLAGS -mno-ms-bitfields"
        DEPS="gcc-mingw-w64-base"
        case "$TEST" in
@@ -76,7 +78,7 @@ win*)
                DEPS="gcc-mingw-w64-x86-64 binutils-mingw-w64-x86-64 mingw-w64-x86-64-dev $DEPS"
                CC="x86_64-w64-mingw32-gcc"
                # apply patch to MinGW headers
-               if test -z "$1"; then
+               if test "$APPVEYOR" != "True" -a -z "$1"; then
                        sudo patch -f -p 4 -d /usr/share/mingw-w64/include < src/libcharon/plugins/kernel_wfp/mingw-w64-4.8.1.diff
                fi
                ;;