From a504809079622f2d02eca2760c0203910ea19044 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Claudio=20Andr=C3=A9?= Date: Sun, 26 Nov 2017 16:58:26 -0200 Subject: [PATCH] CI: run the encoding tests on its own job --- .travis.yml | 8 ++++++++ .travis/check.sh | 4 ++-- .travis/test.sh | 31 +++++++++++++++++++------------ 3 files changed, 29 insertions(+), 14 deletions(-) diff --git a/.travis.yml b/.travis.yml index ae9ffb7f287..086da66e846 100644 --- a/.travis.yml +++ b/.travis.yml @@ -26,6 +26,14 @@ matrix: env: ASAN="--enable-asan" TEST="fresh test" group: deprecated-2017Q3 + - os: linux + compiler: gcc + env: ASAN="" OPENCL="yes" TEST="encoding" + + - os: linux + compiler: clang + env: ASAN="" OPENCL="yes" TEST="encoding" + - os: osx osx_image: xcode8.3 env: ASAN="" OPENCL="yes" diff --git a/.travis/check.sh b/.travis/check.sh index 0c3013c2615..65197449f49 100755 --- a/.travis/check.sh +++ b/.travis/check.sh @@ -9,7 +9,7 @@ if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then ../.travis/test.sh -elif [[ -z "$TEST" ]]; then +elif [[ -z "$TEST" || "$TEST" == "encoding" ]]; then cd src # Build and run with the address sanitizer instrumented code @@ -38,7 +38,7 @@ elif [[ -z "$TEST" ]]; then ./configure CPPFLAGS=-mno-avx2 $ASAN make -sj4 - ../.travis/test.sh + ../.travis/test.sh "$TEST" elif [[ "$TEST" == "fresh test" ]]; then # ASAN using a 'recent' compiler diff --git a/.travis/test.sh b/.travis/test.sh index 2c382dbf391..59270ceab41 100755 --- a/.travis/test.sh +++ b/.travis/test.sh @@ -6,20 +6,27 @@ echo 'Raw-SHA512-free-opencl = Y' >> john-local.conf echo 'XSHA512-free-opencl = Y' >> john-local.conf echo 'gpg-opencl = Y' >> john-local.conf -# Proper testing. Trusty AMD GPU drivers on Travis are fragile -if test "$PROBLEM" = "slow" ; then - ../run/john -test=0 --format=cpu - ../run/john -test=0 --format=cpu --encoding=utf8 - ../run/john -test=0 --format=cpu --encoding=cp737 -else - ../run/john -test-full=0 --format=cpu +if test "$1" = "encoding" ; then ../run/john -test-full=0 --format=cpu --encoding=utf8 + echo ../run/john -test-full=0 --format=cpu --encoding=cp737 -fi -if test "$OPENCL" = "yes" ; then - ../run/john -test-full=0 --format=opencl - ../run/john -test-full=0 --format=opencl --encoding=utf8 - ../run/john -test-full=0 --format=opencl --encoding=cp737 + if test "$OPENCL" = "yes" ; then + ../run/john -test-full=0 --format=opencl --encoding=utf8 + echo + ../run/john -test-full=0 --format=opencl --encoding=cp737 + fi +else + + # Proper testing. Trusty AMD GPU drivers on Travis are fragile + if test "$PROBLEM" = "slow" ; then + ../run/john -test=0 --format=cpu + else + ../run/john -test-full=0 --format=cpu + fi + + if test "$OPENCL" = "yes" ; then + ../run/john -test-full=0 --format=opencl + fi fi