From 3c218901a25fccad320a159883c3f81cca8f77be Mon Sep 17 00:00:00 2001
From: jonny <ga86lad@mytum.de>
Date: Wed, 29 Dec 2021 02:00:48 +0100
Subject: [PATCH] readd pipefail

---
 .gitlab-ci.yml    | 2 +-
 test/run-tests.sh | 5 ++++-
 2 files changed, 5 insertions(+), 2 deletions(-)

diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index ba5b1fc..c52508f 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -26,7 +26,7 @@ run-test:
   script:
     - chmod 777 -R ./test
     - cd ./test
-    - ./test/run-tests.sh
+    - ./run-tests.sh
   artifacts:
     expire_in: 7 days
     when: always
diff --git a/test/run-tests.sh b/test/run-tests.sh
index fede534..abe3b93 100644
--- a/test/run-tests.sh
+++ b/test/run-tests.sh
@@ -3,6 +3,8 @@ TEST_FOLDERS=$(ls -d */)
 
 FAILED=0
 
+set -euo pipefail
+
 if ! command -v jq &> /dev/null
 then
   apt-get update
@@ -15,7 +17,7 @@ do
     if [ "$dir" != "test-output" ]; then
         echo "running for $dir"
         EXPECTED=$(jq . "./${dir}/output.json")
-        ACTUAL=$(cd .. && stack run -- walint --repository ./test/${dir} --config-file ./config.json --json --pretty | jq && cd test)
+        ACTUAL=$(cd .. && stack run -- walint --repository ./test/${dir} --config-file ./config.json --json --pretty | jq && cd test) || true
 
 
         if [ "$EXPECTED" != "$ACTUAL" ]; then
@@ -27,5 +29,6 @@ do
     fi
 done
 
+echo "finished"
 exit $FAILED
     
\ No newline at end of file
-- 
GitLab