From 59daae3bc803c9a722fcd5c7a17092fffc72eee8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?St=C3=A9phane=20Adjemian=28Charybdis=29?= <stephane.adjemian@univ-lemans.fr> Date: Sat, 15 Sep 2018 13:35:57 +0200 Subject: [PATCH] Define exit code in Makefile. --- Makefile | 4 ++-- success.sh | 8 -------- 2 files changed, 2 insertions(+), 10 deletions(-) delete mode 100755 success.sh diff --git a/Makefile b/Makefile index 3967002..dc90165 100644 --- a/Makefile +++ b/Makefile @@ -5,10 +5,10 @@ all: check-octave check-matlab check-octave: @cd tests ;\ - $(OCTAVE) --no-init-file --silent --no-history --eval "addpath([pwd() '/../m-unit-tests/src']); runalltests" + $(OCTAVE) --no-init-file --silent --no-history --eval "addpath([pwd() '/../m-unit-tests/src']); runalltests" && [ ! -f ./failed ] && [ -f ./pass ] check-matlab: - @$(MATLAB) -nosplash -nodisplay -r "addpath m-unit-tests/src; cd tests; runalltests; quit" + @$(MATLAB) -nosplash -nodisplay -r "addpath m-unit-tests/src; cd tests; runalltests; quit" && [ ! -f ./tests/failed ] && [ -f ./tests/pass ] check-clean: rm -f tests/*_test_*.m tests/*.csv tests/*.xls tests/*.xlsx tests/*.mat tests/failed tests/datafile_for_test diff --git a/success.sh b/success.sh deleted file mode 100755 index 650a7d0..0000000 --- a/success.sh +++ /dev/null @@ -1,8 +0,0 @@ -#!/bin/bash -if [[ -f ./tests/failed ]]; then - exit 1 -elif [[ -f ./tests/pass ]]; then - exit 0 -else - exit 1 -fi -- GitLab