diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index af480e677af3715aed02419b1709b4d20ba2e3d5..1e7af8724042429326c2ad3ab13a89d1fd8655c5 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -8,4 +8,18 @@ before_script: test_matlab: stage: test script: - - make check-matlab \ No newline at end of file + - make check-matlab + +test_old_matlab: + stage: test + variables: + MATLAB: /usr/local/MATLAB/R2009b/bin/matlab + script: + - make check-matlab + +test_octave: + stage: test + variables: + OPENBLAS_NUM_THREADS: 1 + script: + - make check-octave \ No newline at end of file diff --git a/Makefile b/Makefile index 926f34e1c6b265faaa8e9f8ea8ef6ae9cc047a25..6c1b562af5be3c36a9cbf57fd29b08463ba612cb 100644 --- a/Makefile +++ b/Makefile @@ -1,15 +1,19 @@ OCTAVE ?= octave-cli MATLAB ?= $(shell which matlab) -all: check-matlab +all: check-octave check-matlab m-unit-tests/src/mtest.m: git clone https://git.dynare.org/Dynare/m-unit-tests +check-octave: m-unit-tests/src/mtest.m + @cd tests ;\ + $(OCTAVE) --no-init-file --silent --no-history --eval "addpath([pwd() '/../m-unit-tests/src']); runalltests" && [ ! -f ./failed ] && [ -f ./pass ] + check-matlab: m-unit-tests/src/mtest.m @$(MATLAB) -nosplash -nodisplay -r "addpath([pwd '/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 rm -f git.info git.last-commit-hash tests/pass tests/failed tests/*.spc - rm -rf m-unit-tests + rm -rf m-unit-tests \ No newline at end of file