From f22e0136817b055ffd98b95d40cf4f8af7efed81 Mon Sep 17 00:00:00 2001 From: Helge <47348963+HJZollner@users.noreply.github.com> Date: Tue, 20 Jul 2021 15:33:14 -0400 Subject: [PATCH 01/27] Update azure-pipelines-develop-pull.yml for Azure Pipelines --- ci/azure-pipelines-develop-pull.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ci/azure-pipelines-develop-pull.yml b/ci/azure-pipelines-develop-pull.yml index 7db15ce8..b081bbfc 100644 --- a/ci/azure-pipelines-develop-pull.yml +++ b/ci/azure-pipelines-develop-pull.yml @@ -3,8 +3,8 @@ # Starts with a quick Single Subject PRESS test # If the first stage is successful a Full PRESS job is triggered -trigger: -- develop +trigger: [ develop ] +pr: [ develop ] pool: 'Default' From c2ae757c8607c128bd5f587e024560a373e1caff Mon Sep 17 00:00:00 2001 From: Helge <47348963+HJZollner@users.noreply.github.com> Date: Tue, 20 Jul 2021 15:44:56 -0400 Subject: [PATCH 02/27] Delete azure-pipelines-master-pull.yml --- ci/azure-pipelines-master-pull.yml | 24 ------------------------ 1 file changed, 24 deletions(-) delete mode 100644 ci/azure-pipelines-master-pull.yml diff --git a/ci/azure-pipelines-master-pull.yml b/ci/azure-pipelines-master-pull.yml deleted file mode 100644 index b2af7500..00000000 --- a/ci/azure-pipelines-master-pull.yml +++ /dev/null @@ -1,24 +0,0 @@ -# Pull request CI pipeline for Osprey -# Triggers for each pull request into the master branch -# Starts with a quick Full PRESS job -# If the first stage is successful a Full MEGA job is triggered - -trigger: -- master - -pool: 'Default' - -stages: -- stage: FullPRESS - jobs: - - job: FullPRESS - steps: - - script: matlab -nodisplay -wait -nosplash -r " FullPRESS; quit" - displayName: 'Full PRESS with Segmentation & GUI' - -- stage: FullMEGA - jobs: - - job: FullMEGA - steps: - - script: matlab -nodisplay -wait -nosplash -r " FullMEGA; quit" - displayName: 'Full MEGA add Segmentation & GUI' \ No newline at end of file From 7578cf24fc833e0047208ae3cd732fa68f54c22c Mon Sep 17 00:00:00 2001 From: Helge <47348963+HJZollner@users.noreply.github.com> Date: Tue, 20 Jul 2021 16:31:48 -0400 Subject: [PATCH 03/27] Continuous Integration #11 Test whether the develop branch triggers a pull request and test --- plot/osp_plotProcess.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plot/osp_plotProcess.m b/plot/osp_plotProcess.m index 30c53308..aa6e8911 100755 --- a/plot/osp_plotProcess.m +++ b/plot/osp_plotProcess.m @@ -45,7 +45,7 @@ if nargin<6 switch which_spec case {'A', 'B', 'C', 'D', 'diff1', 'diff2','diff3', 'sum','mm'} - ppmmax = 8; + ppmmax = 10; case {'ref', 'w'} ppmmax = 2*4.68; otherwise From 8a3b1e326546f8a7d49baa7ce88c9c21ebfaff54 Mon Sep 17 00:00:00 2001 From: Helge <47348963+HJZollner@users.noreply.github.com> Date: Tue, 20 Jul 2021 16:55:16 -0400 Subject: [PATCH 04/27] Update azure-pipelines-develop-pull.yml for Azure Pipelines --- ci/azure-pipelines-develop-pull.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ci/azure-pipelines-develop-pull.yml b/ci/azure-pipelines-develop-pull.yml index b081bbfc..8181f62c 100644 --- a/ci/azure-pipelines-develop-pull.yml +++ b/ci/azure-pipelines-develop-pull.yml @@ -13,7 +13,7 @@ stages: jobs: - job: PRESS steps: - - script: matlab -nodisplay -wait -nosplash -r " SinglePRESS; quit" + - script: matlab -nodisplay -wait -nosplash -r "addpath('C:\CI-agent\_work\1\s'); SinglePRESS; quit" displayName: 'Single Subject PRESS without Segmentation & GUI' - stage: PRESSdownstream @@ -21,5 +21,5 @@ stages: jobs: - job: PRESSdownstream steps: - - script: matlab -nodisplay -wait -nosplash -r " SinglePRESSdownstream; quit" + - script: matlab -nodisplay -wait -nosplash -r "addpath('C:\CI-agent\_work\1\s'); SinglePRESSdownstream; quit" displayName: 'Single Subject PRESS add Segmentation & GUI' \ No newline at end of file From 4f3a6b48a6654d2ed687b9180b3b7ece82d77d50 Mon Sep 17 00:00:00 2001 From: Helge <47348963+HJZollner@users.noreply.github.com> Date: Tue, 20 Jul 2021 16:59:39 -0400 Subject: [PATCH 05/27] Update azure-pipelines-develop-pull.yml for Azure Pipelines --- ci/azure-pipelines-develop-pull.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ci/azure-pipelines-develop-pull.yml b/ci/azure-pipelines-develop-pull.yml index 8181f62c..83bb8b0b 100644 --- a/ci/azure-pipelines-develop-pull.yml +++ b/ci/azure-pipelines-develop-pull.yml @@ -13,7 +13,7 @@ stages: jobs: - job: PRESS steps: - - script: matlab -nodisplay -wait -nosplash -r "addpath('C:\CI-agent\_work\1\s'); SinglePRESS; quit" + - script: matlab -nodisplay -wait -nosplash -r "addpath(genpath('C:\CI-agent\_work\1\s')); SinglePRESS; quit" displayName: 'Single Subject PRESS without Segmentation & GUI' - stage: PRESSdownstream @@ -21,5 +21,5 @@ stages: jobs: - job: PRESSdownstream steps: - - script: matlab -nodisplay -wait -nosplash -r "addpath('C:\CI-agent\_work\1\s'); SinglePRESSdownstream; quit" + - script: matlab -nodisplay -wait -nosplash -r "addpath(genpath('C:\CI-agent\_work\1\s')); SinglePRESSdownstream; quit" displayName: 'Single Subject PRESS add Segmentation & GUI' \ No newline at end of file From 06dc9dfbef60cddf1854d257e242a5aee836014b Mon Sep 17 00:00:00 2001 From: Helge <47348963+HJZollner@users.noreply.github.com> Date: Tue, 20 Jul 2021 17:10:51 -0400 Subject: [PATCH 06/27] Update azure-pipelines-develop-pull.yml for Azure Pipelines --- ci/azure-pipelines-develop-pull.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ci/azure-pipelines-develop-pull.yml b/ci/azure-pipelines-develop-pull.yml index 83bb8b0b..138b1ddc 100644 --- a/ci/azure-pipelines-develop-pull.yml +++ b/ci/azure-pipelines-develop-pull.yml @@ -9,15 +9,15 @@ pr: [ develop ] pool: 'Default' stages: -- stage: PRESS +- stage: Stage_1 jobs: - job: PRESS steps: - script: matlab -nodisplay -wait -nosplash -r "addpath(genpath('C:\CI-agent\_work\1\s')); SinglePRESS; quit" displayName: 'Single Subject PRESS without Segmentation & GUI' -- stage: PRESSdownstream - dependsOn: PRESS +- stage: Stage_2 + dependsOn: Stage_1 jobs: - job: PRESSdownstream steps: From b6e7116b15610ab74452c97e6830fb6abd91333b Mon Sep 17 00:00:00 2001 From: Helge <47348963+HJZollner@users.noreply.github.com> Date: Tue, 20 Jul 2021 17:16:37 -0400 Subject: [PATCH 07/27] Update azure-pipelines-develop-pull.yml for Azure Pipelines [ci skip] --- ci/azure-pipelines-develop-pull.yml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/ci/azure-pipelines-develop-pull.yml b/ci/azure-pipelines-develop-pull.yml index 138b1ddc..05520d14 100644 --- a/ci/azure-pipelines-develop-pull.yml +++ b/ci/azure-pipelines-develop-pull.yml @@ -3,8 +3,13 @@ # Starts with a quick Single Subject PRESS test # If the first stage is successful a Full PRESS job is triggered -trigger: [ develop ] -pr: [ develop ] +trigger: + branches: + include: + - develop + exclude: + - master + pool: 'Default' From b88f42fc09503b09da4b6cf5c409e0c829c39c70 Mon Sep 17 00:00:00 2001 From: Helge <47348963+HJZollner@users.noreply.github.com> Date: Tue, 20 Jul 2021 17:19:17 -0400 Subject: [PATCH 08/27] Continuous Integration #12 Try again. Updated the branch checkout on the server --- plot/osp_plotProcess.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plot/osp_plotProcess.m b/plot/osp_plotProcess.m index aa6e8911..80be6bd8 100755 --- a/plot/osp_plotProcess.m +++ b/plot/osp_plotProcess.m @@ -45,7 +45,7 @@ if nargin<6 switch which_spec case {'A', 'B', 'C', 'D', 'diff1', 'diff2','diff3', 'sum','mm'} - ppmmax = 10; + ppmmax = 4.2; case {'ref', 'w'} ppmmax = 2*4.68; otherwise From d267fe50d8ab04ecdd79bf396e77d40efe961199 Mon Sep 17 00:00:00 2001 From: Helge <47348963+HJZollner@users.noreply.github.com> Date: Wed, 21 Jul 2021 09:47:14 -0400 Subject: [PATCH 09/27] Continuous Integration #13 Added a deliberate bug to test the CI --- job/OspreyJob.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/job/OspreyJob.m b/job/OspreyJob.m index 19713940..f00219fb 100755 --- a/job/OspreyJob.m +++ b/job/OspreyJob.m @@ -45,7 +45,7 @@ %%% 1. INITIALISE DATA CONTAINER WITH DEFAULT SETTINGS [MRSCont] = OspreySettings; - +HorribleBug %%% 2. CHECK JOB INPUT FILE FORMAT %%% [~,~,ext] = fileparts(jobFile); switch ext From d4b23a633fad723b1d1b0a3bbefc72cdd48b177b Mon Sep 17 00:00:00 2001 From: Helge <47348963+HJZollner@users.noreply.github.com> Date: Wed, 21 Jul 2021 09:52:11 -0400 Subject: [PATCH 10/27] Revert "Continuous Integration #13" --- job/OspreyJob.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/job/OspreyJob.m b/job/OspreyJob.m index f00219fb..19713940 100755 --- a/job/OspreyJob.m +++ b/job/OspreyJob.m @@ -45,7 +45,7 @@ %%% 1. INITIALISE DATA CONTAINER WITH DEFAULT SETTINGS [MRSCont] = OspreySettings; -HorribleBug + %%% 2. CHECK JOB INPUT FILE FORMAT %%% [~,~,ext] = fileparts(jobFile); switch ext From 21e327923d28de7c600ed9d677ede7d31e3d3497 Mon Sep 17 00:00:00 2001 From: Helge <47348963+HJZollner@users.noreply.github.com> Date: Wed, 21 Jul 2021 10:11:16 -0400 Subject: [PATCH 11/27] Update azure-pipelines-develop-pull.yml for Azure Pipelines [ci skip]] --- ci/azure-pipelines-develop-pull.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ci/azure-pipelines-develop-pull.yml b/ci/azure-pipelines-develop-pull.yml index 05520d14..41128722 100644 --- a/ci/azure-pipelines-develop-pull.yml +++ b/ci/azure-pipelines-develop-pull.yml @@ -18,7 +18,7 @@ stages: jobs: - job: PRESS steps: - - script: matlab -nodisplay -wait -nosplash -r "addpath(genpath('C:\CI-agent\_work\1\s')); SinglePRESS; quit" + - script: matlab -nodisplay -wait -nosplash -r "addpath(genpath('C:\CI-agent\_work\1\s')); SinglePRESS; assert(exit_code > 0); quit" displayName: 'Single Subject PRESS without Segmentation & GUI' - stage: Stage_2 @@ -26,5 +26,5 @@ stages: jobs: - job: PRESSdownstream steps: - - script: matlab -nodisplay -wait -nosplash -r "addpath(genpath('C:\CI-agent\_work\1\s')); SinglePRESSdownstream; quit" + - script: matlab -nodisplay -wait -nosplash -r "addpath(genpath('C:\CI-agent\_work\1\s')); SinglePRESSdownstream; assert(exit_code > 0); quit" displayName: 'Single Subject PRESS add Segmentation & GUI' \ No newline at end of file From d4893e3ce2684e4f1d51bd640c69547ab1e08050 Mon Sep 17 00:00:00 2001 From: Helge <47348963+HJZollner@users.noreply.github.com> Date: Wed, 21 Jul 2021 10:13:25 -0400 Subject: [PATCH 12/27] Continuous Integration #14 [ci skip] - Add assert statement to verify successful test --- ci/FullMEGA.m | 6 +----- ci/FullPRESS.m | 5 +---- ci/SinglePRESS.m | 4 ---- ci/SinglePRESSdownstream.m | 3 --- job/OspreyJob.m | 1 - 5 files changed, 2 insertions(+), 17 deletions(-) diff --git a/ci/FullMEGA.m b/ci/FullMEGA.m index b35b22f8..98e8660d 100644 --- a/ci/FullMEGA.m +++ b/ci/FullMEGA.m @@ -7,8 +7,4 @@ % check the result if sum(rt{1}.Failed) == 0 && sum(rt{1}.Incomplete) == 0 &&sum(rt{2}.Failed) == 0 && sum(rt{2}.Incomplete) == 0 exit_code = 0; -end - - -% Ensure that we ALWAYS call exit that is always a success so that CI doesn't stop -exit \ No newline at end of file +end \ No newline at end of file diff --git a/ci/FullPRESS.m b/ci/FullPRESS.m index 9a14f514..34bbd954 100644 --- a/ci/FullPRESS.m +++ b/ci/FullPRESS.m @@ -7,7 +7,4 @@ % check the result if sum(rt{1}.Failed) == 0 && sum(rt{1}.Incomplete) == 0 &&sum(rt{2}.Failed) == 0 && sum(rt{2}.Incomplete) == 0 exit_code = 0; -end - -% Ensure that we ALWAYS call exit that is always a success so that CI doesn't stop -exit \ No newline at end of file +end \ No newline at end of file diff --git a/ci/SinglePRESS.m b/ci/SinglePRESS.m index 7a916574..ed0bc159 100644 --- a/ci/SinglePRESS.m +++ b/ci/SinglePRESS.m @@ -8,7 +8,3 @@ if sum(rt{1}.Failed) == 0 && sum(rt{1}.Incomplete) == 0 exit_code = 0; end - - -% Ensure that we ALWAYS call exit that is always a success so that CI doesn't stop -exit \ No newline at end of file diff --git a/ci/SinglePRESSdownstream.m b/ci/SinglePRESSdownstream.m index 20ef3c53..d8033fa3 100644 --- a/ci/SinglePRESSdownstream.m +++ b/ci/SinglePRESSdownstream.m @@ -8,6 +8,3 @@ if sum(rt{1}.Failed) == 0 && sum(rt{1}.Incomplete) == 0 &&sum(rt{2}.Failed) == 0 && sum(rt{2}.Incomplete) == 0 exit_code = 0; end - -% Ensure that we ALWAYS call exit that is always a success so that CI doesn't stop -exit \ No newline at end of file diff --git a/job/OspreyJob.m b/job/OspreyJob.m index f00219fb..d6323f94 100755 --- a/job/OspreyJob.m +++ b/job/OspreyJob.m @@ -45,7 +45,6 @@ %%% 1. INITIALISE DATA CONTAINER WITH DEFAULT SETTINGS [MRSCont] = OspreySettings; -HorribleBug %%% 2. CHECK JOB INPUT FILE FORMAT %%% [~,~,ext] = fileparts(jobFile); switch ext From b3c49606d5515d33d5b91fb9785336cb50de2544 Mon Sep 17 00:00:00 2001 From: Helge <47348963+HJZollner@users.noreply.github.com> Date: Wed, 21 Jul 2021 10:28:15 -0400 Subject: [PATCH 13/27] Update azure-pipelines-develop-pull.yml for Azure Pipelines [ci skip] --- ci/azure-pipelines-develop-pull.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ci/azure-pipelines-develop-pull.yml b/ci/azure-pipelines-develop-pull.yml index 41128722..d2fea0b8 100644 --- a/ci/azure-pipelines-develop-pull.yml +++ b/ci/azure-pipelines-develop-pull.yml @@ -18,7 +18,7 @@ stages: jobs: - job: PRESS steps: - - script: matlab -nodisplay -wait -nosplash -r "addpath(genpath('C:\CI-agent\_work\1\s')); SinglePRESS; assert(exit_code > 0); quit" + - script: matlab -nodisplay -wait -nosplash -r "addpath(genpath('C:\CI-agent\_work\1\s')); exit_code = SinglePRESS; assert(exit_code > 0); quit" displayName: 'Single Subject PRESS without Segmentation & GUI' - stage: Stage_2 @@ -26,5 +26,5 @@ stages: jobs: - job: PRESSdownstream steps: - - script: matlab -nodisplay -wait -nosplash -r "addpath(genpath('C:\CI-agent\_work\1\s')); SinglePRESSdownstream; assert(exit_code > 0); quit" + - script: matlab -nodisplay -wait -nosplash -r "addpath(genpath('C:\CI-agent\_work\1\s')); exit_code = SinglePRESSdownstream; assert(exit_code > 0); quit" displayName: 'Single Subject PRESS add Segmentation & GUI' \ No newline at end of file From 3fb861335c6ca8d53bdd6638fecccce3d7d18675 Mon Sep 17 00:00:00 2001 From: Helge <47348963+HJZollner@users.noreply.github.com> Date: Wed, 21 Jul 2021 10:29:41 -0400 Subject: [PATCH 14/27] Continuous Integration #15 [ci skip] - add assertion code to function [ci skip] --- ci/SinglePRESS.m | 18 ++++++++++-------- ci/SinglePRESSdownstream.m | 18 ++++++++++-------- 2 files changed, 20 insertions(+), 16 deletions(-) diff --git a/ci/SinglePRESS.m b/ci/SinglePRESS.m index ed0bc159..0e7fd09c 100644 --- a/ci/SinglePRESS.m +++ b/ci/SinglePRESS.m @@ -1,10 +1,12 @@ -% assume it always fails -exit_code = 1; +function [exit_code] = SinglePRESS + % assume it always fails + exit_code = 1; -% MATLAB runs the test -[result,rt] = UnitTest('SinglePRESS',0,0); + % MATLAB runs the test + [result,rt] = UnitTest('SinglePRESS',0,0); -% check the result -if sum(rt{1}.Failed) == 0 && sum(rt{1}.Incomplete) == 0 - exit_code = 0; -end + % check the result + if sum(rt{1}.Failed) == 0 && sum(rt{1}.Incomplete) == 0 + exit_code = 0; + end +end \ No newline at end of file diff --git a/ci/SinglePRESSdownstream.m b/ci/SinglePRESSdownstream.m index d8033fa3..87087b9e 100644 --- a/ci/SinglePRESSdownstream.m +++ b/ci/SinglePRESSdownstream.m @@ -1,10 +1,12 @@ -% assume it always fails -exit_code = 1; +function [exit_code] = SinglePRESSdownstream + % assume it always fails + exit_code = 1; -% MATLAB runs the test -[result,rt] = UnitTest('SinglePRESS',2,1); + % MATLAB runs the test + [result,rt] = UnitTest('SinglePRESS',2,1); -% check the result -if sum(rt{1}.Failed) == 0 && sum(rt{1}.Incomplete) == 0 &&sum(rt{2}.Failed) == 0 && sum(rt{2}.Incomplete) == 0 - exit_code = 0; -end + % check the result + if sum(rt{1}.Failed) == 0 && sum(rt{1}.Incomplete) == 0 &&sum(rt{2}.Failed) == 0 && sum(rt{2}.Incomplete) == 0 + exit_code = 0; + end +end \ No newline at end of file From edfab605b8049907e653285ecb634039be000ddc Mon Sep 17 00:00:00 2001 From: Helge <47348963+HJZollner@users.noreply.github.com> Date: Wed, 21 Jul 2021 11:06:54 -0400 Subject: [PATCH 15/27] Update azure-pipelines-develop-pull.yml for Azure Pipelines [ci skip] [ci skip] --- ci/azure-pipelines-develop-pull.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ci/azure-pipelines-develop-pull.yml b/ci/azure-pipelines-develop-pull.yml index d2fea0b8..8b452b5c 100644 --- a/ci/azure-pipelines-develop-pull.yml +++ b/ci/azure-pipelines-develop-pull.yml @@ -18,7 +18,7 @@ stages: jobs: - job: PRESS steps: - - script: matlab -nodisplay -wait -nosplash -r "addpath(genpath('C:\CI-agent\_work\1\s')); exit_code = SinglePRESS; assert(exit_code > 0); quit" + - script: matlab -nodisplay -wait -nosplash -r "addpath(genpath('C:\CI-agent\_work\1\s')); exit_code = SinglePRESS; quit" displayName: 'Single Subject PRESS without Segmentation & GUI' - stage: Stage_2 @@ -26,5 +26,5 @@ stages: jobs: - job: PRESSdownstream steps: - - script: matlab -nodisplay -wait -nosplash -r "addpath(genpath('C:\CI-agent\_work\1\s')); exit_code = SinglePRESSdownstream; assert(exit_code > 0); quit" + - script: matlab -nodisplay -wait -nosplash -r "addpath(genpath('C:\CI-agent\_work\1\s')); exit_code = SinglePRESSdownstream; quit" displayName: 'Single Subject PRESS add Segmentation & GUI' \ No newline at end of file From dce75aeaa23a23bd06456a1acce8218665e01ceb Mon Sep 17 00:00:00 2001 From: Helge <47348963+HJZollner@users.noreply.github.com> Date: Wed, 21 Jul 2021 11:09:13 -0400 Subject: [PATCH 16/27] Update azure-pipelines-develop-pull.yml for Azure Pipelines [ci skip] [ci skip] --- ci/azure-pipelines-develop-pull.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ci/azure-pipelines-develop-pull.yml b/ci/azure-pipelines-develop-pull.yml index 8b452b5c..d20cba3f 100644 --- a/ci/azure-pipelines-develop-pull.yml +++ b/ci/azure-pipelines-develop-pull.yml @@ -18,7 +18,7 @@ stages: jobs: - job: PRESS steps: - - script: matlab -nodisplay -wait -nosplash -r "addpath(genpath('C:\CI-agent\_work\1\s')); exit_code = SinglePRESS; quit" + - script: matlab -nodisplay -wait -nosplash -batch "addpath(genpath('C:\CI-agent\_work\1\s')); exit_code = SinglePRESS; quit" displayName: 'Single Subject PRESS without Segmentation & GUI' - stage: Stage_2 @@ -26,5 +26,5 @@ stages: jobs: - job: PRESSdownstream steps: - - script: matlab -nodisplay -wait -nosplash -r "addpath(genpath('C:\CI-agent\_work\1\s')); exit_code = SinglePRESSdownstream; quit" + - script: matlab -nodisplay -wait -nosplash -batch "addpath(genpath('C:\CI-agent\_work\1\s')); exit_code = SinglePRESSdownstream; quit" displayName: 'Single Subject PRESS add Segmentation & GUI' \ No newline at end of file From c0b970f4f689f14b6ff29f5aa9c0b3d547243f91 Mon Sep 17 00:00:00 2001 From: Helge <47348963+HJZollner@users.noreply.github.com> Date: Wed, 21 Jul 2021 11:25:30 -0400 Subject: [PATCH 17/27] CI #16 Added a new bug for testing --- job/OspreyJob.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/job/OspreyJob.m b/job/OspreyJob.m index d6323f94..af3558d4 100755 --- a/job/OspreyJob.m +++ b/job/OspreyJob.m @@ -44,7 +44,7 @@ %%% 1. INITIALISE DATA CONTAINER WITH DEFAULT SETTINGS [MRSCont] = OspreySettings; - +HugeBug %%% 2. CHECK JOB INPUT FILE FORMAT %%% [~,~,ext] = fileparts(jobFile); switch ext From 2a2a5eaefa3806a8184df1a4430cda922bac98b8 Mon Sep 17 00:00:00 2001 From: Helge <47348963+HJZollner@users.noreply.github.com> Date: Wed, 21 Jul 2021 11:37:13 -0400 Subject: [PATCH 18/27] Update azure-pipelines-develop-pull.yml for Azure Pipelines [ci skip] [ci skip] --- ci/azure-pipelines-develop-pull.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ci/azure-pipelines-develop-pull.yml b/ci/azure-pipelines-develop-pull.yml index d20cba3f..4a32b524 100644 --- a/ci/azure-pipelines-develop-pull.yml +++ b/ci/azure-pipelines-develop-pull.yml @@ -18,7 +18,7 @@ stages: jobs: - job: PRESS steps: - - script: matlab -nodisplay -wait -nosplash -batch "addpath(genpath('C:\CI-agent\_work\1\s')); exit_code = SinglePRESS; quit" + - script: matlab -nodisplay -wait -nosplash -batch "addpath(genpath('C:\CI-agent\_work\1\s')); exit_code = SinglePRESS; assert(exit_code > 1); quit" displayName: 'Single Subject PRESS without Segmentation & GUI' - stage: Stage_2 @@ -26,5 +26,5 @@ stages: jobs: - job: PRESSdownstream steps: - - script: matlab -nodisplay -wait -nosplash -batch "addpath(genpath('C:\CI-agent\_work\1\s')); exit_code = SinglePRESSdownstream; quit" + - script: matlab -nodisplay -wait -nosplash -batch "addpath(genpath('C:\CI-agent\_work\1\s')); exit_code = SinglePRESSdownstream; assert(exit_code > 1); quit" displayName: 'Single Subject PRESS add Segmentation & GUI' \ No newline at end of file From 98de0d0267a3e51108a82081beb5bcf76a262fdc Mon Sep 17 00:00:00 2001 From: Helge <47348963+HJZollner@users.noreply.github.com> Date: Wed, 21 Jul 2021 11:43:22 -0400 Subject: [PATCH 19/27] Update azure-pipelines-develop-pull.yml for Azure Pipelines [skip ci] [skip ci] --- ci/azure-pipelines-develop-pull.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ci/azure-pipelines-develop-pull.yml b/ci/azure-pipelines-develop-pull.yml index 4a32b524..8c700261 100644 --- a/ci/azure-pipelines-develop-pull.yml +++ b/ci/azure-pipelines-develop-pull.yml @@ -3,7 +3,7 @@ # Starts with a quick Single Subject PRESS test # If the first stage is successful a Full PRESS job is triggered -trigger: +pr: branches: include: - develop From 13bdc7dfe7b76d540286b12bf6bf7aebefd33a2c Mon Sep 17 00:00:00 2001 From: Helge <47348963+HJZollner@users.noreply.github.com> Date: Wed, 21 Jul 2021 11:44:07 -0400 Subject: [PATCH 20/27] CI #17 Remove the deliberate bug --- job/OspreyJob.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/job/OspreyJob.m b/job/OspreyJob.m index af3558d4..d6323f94 100755 --- a/job/OspreyJob.m +++ b/job/OspreyJob.m @@ -44,7 +44,7 @@ %%% 1. INITIALISE DATA CONTAINER WITH DEFAULT SETTINGS [MRSCont] = OspreySettings; -HugeBug + %%% 2. CHECK JOB INPUT FILE FORMAT %%% [~,~,ext] = fileparts(jobFile); switch ext From 76c353b1180229c0b752c14f2581ceb97128fffe Mon Sep 17 00:00:00 2001 From: Helge <47348963+HJZollner@users.noreply.github.com> Date: Wed, 21 Jul 2021 11:58:19 -0400 Subject: [PATCH 21/27] CI #19 - Move assertion into the test --- ci/SinglePRESS.m | 10 +--------- ci/SinglePRESSdownstream.m | 9 +-------- extdata/ABfit.BASIS | 1 + 3 files changed, 3 insertions(+), 17 deletions(-) create mode 100644 extdata/ABfit.BASIS diff --git a/ci/SinglePRESS.m b/ci/SinglePRESS.m index 0e7fd09c..a62092c4 100644 --- a/ci/SinglePRESS.m +++ b/ci/SinglePRESS.m @@ -1,12 +1,4 @@ -function [exit_code] = SinglePRESS - % assume it always fails - exit_code = 1; - % MATLAB runs the test [result,rt] = UnitTest('SinglePRESS',0,0); - % check the result - if sum(rt{1}.Failed) == 0 && sum(rt{1}.Incomplete) == 0 - exit_code = 0; - end -end \ No newline at end of file + assert(sum(rt{1}.Failed) == 0 && sum(rt{1}.Incomplete) == 0) diff --git a/ci/SinglePRESSdownstream.m b/ci/SinglePRESSdownstream.m index 87087b9e..12007309 100644 --- a/ci/SinglePRESSdownstream.m +++ b/ci/SinglePRESSdownstream.m @@ -1,12 +1,5 @@ -function [exit_code] = SinglePRESSdownstream - % assume it always fails - exit_code = 1; % MATLAB runs the test [result,rt] = UnitTest('SinglePRESS',2,1); - % check the result - if sum(rt{1}.Failed) == 0 && sum(rt{1}.Incomplete) == 0 &&sum(rt{2}.Failed) == 0 && sum(rt{2}.Incomplete) == 0 - exit_code = 0; - end -end \ No newline at end of file + assert(sum(rt{1}.Failed) == 0 && sum(rt{1}.Incomplete) == 0 &&sum(rt{2}.Failed) == 0 && sum(rt{2}.Incomplete) == 0) \ No newline at end of file diff --git a/extdata/ABfit.BASIS b/extdata/ABfit.BASIS new file mode 100644 index 00000000..9c8296ff --- /dev/null +++ b/extdata/ABfit.BASIS @@ -0,0 +1 @@ + BADELT = 5e-04, From 8cbf30dca16d1db197d3b15eee5a2737a2387396 Mon Sep 17 00:00:00 2001 From: Helge <47348963+HJZollner@users.noreply.github.com> Date: Wed, 21 Jul 2021 12:00:03 -0400 Subject: [PATCH 22/27] Update azure-pipelines-develop-pull.yml for Azure Pipelines [ci skip] [ci skip] --- ci/azure-pipelines-develop-pull.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ci/azure-pipelines-develop-pull.yml b/ci/azure-pipelines-develop-pull.yml index 8c700261..406b7a5a 100644 --- a/ci/azure-pipelines-develop-pull.yml +++ b/ci/azure-pipelines-develop-pull.yml @@ -18,7 +18,7 @@ stages: jobs: - job: PRESS steps: - - script: matlab -nodisplay -wait -nosplash -batch "addpath(genpath('C:\CI-agent\_work\1\s')); exit_code = SinglePRESS; assert(exit_code > 1); quit" + - script: matlab -nodisplay -wait -nosplash -batch "addpath(genpath('C:\CI-agent\_work\1\s')); SinglePRESS; quit" displayName: 'Single Subject PRESS without Segmentation & GUI' - stage: Stage_2 @@ -26,5 +26,5 @@ stages: jobs: - job: PRESSdownstream steps: - - script: matlab -nodisplay -wait -nosplash -batch "addpath(genpath('C:\CI-agent\_work\1\s')); exit_code = SinglePRESSdownstream; assert(exit_code > 1); quit" + - script: matlab -nodisplay -wait -nosplash -batch "addpath(genpath('C:\CI-agent\_work\1\s')); SinglePRESSdownstream; quit" displayName: 'Single Subject PRESS add Segmentation & GUI' \ No newline at end of file From 96073422a820876d05b39688e97f0eb26362cd3a Mon Sep 17 00:00:00 2001 From: Helge <47348963+HJZollner@users.noreply.github.com> Date: Wed, 21 Jul 2021 13:55:55 -0400 Subject: [PATCH 23/27] Update azure-pipelines-develop-pull.yml for Azure Pipelines [skip ci] [skip ci] --- ci/azure-pipelines-develop-pull.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ci/azure-pipelines-develop-pull.yml b/ci/azure-pipelines-develop-pull.yml index 406b7a5a..91a9d6c6 100644 --- a/ci/azure-pipelines-develop-pull.yml +++ b/ci/azure-pipelines-develop-pull.yml @@ -3,7 +3,7 @@ # Starts with a quick Single Subject PRESS test # If the first stage is successful a Full PRESS job is triggered -pr: +trigger: branches: include: - develop From 3a5d74c82ff35352d752b3275bccf6155afa1609 Mon Sep 17 00:00:00 2001 From: Helge <47348963+HJZollner@users.noreply.github.com> Date: Wed, 21 Jul 2021 13:56:57 -0400 Subject: [PATCH 24/27] CI #20 Test new setup --- job/OspreyJob.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/job/OspreyJob.m b/job/OspreyJob.m index d6323f94..520fa386 100755 --- a/job/OspreyJob.m +++ b/job/OspreyJob.m @@ -44,7 +44,7 @@ %%% 1. INITIALISE DATA CONTAINER WITH DEFAULT SETTINGS [MRSCont] = OspreySettings; - +HorribleBug %%% 2. CHECK JOB INPUT FILE FORMAT %%% [~,~,ext] = fileparts(jobFile); switch ext From 2b8e4da4d0e3a626f5e5ac5212135b96c419b8e9 Mon Sep 17 00:00:00 2001 From: Helge <47348963+HJZollner@users.noreply.github.com> Date: Wed, 21 Jul 2021 13:58:55 -0400 Subject: [PATCH 25/27] Revert "CI #20" --- job/OspreyJob.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/job/OspreyJob.m b/job/OspreyJob.m index 520fa386..d6323f94 100755 --- a/job/OspreyJob.m +++ b/job/OspreyJob.m @@ -44,7 +44,7 @@ %%% 1. INITIALISE DATA CONTAINER WITH DEFAULT SETTINGS [MRSCont] = OspreySettings; -HorribleBug + %%% 2. CHECK JOB INPUT FILE FORMAT %%% [~,~,ext] = fileparts(jobFile); switch ext From f640ff698ad5dfb85772bb5fd06c831e922b5cec Mon Sep 17 00:00:00 2001 From: Helge <47348963+HJZollner@users.noreply.github.com> Date: Wed, 21 Jul 2021 14:07:50 -0400 Subject: [PATCH 26/27] CI #21 [ci skip] - update the master-pull jobs to have the same structure as the develop-pull jobs [ci skip] --- ci/FullMEGA.m | 8 +------- ci/FullPRESS.m | 8 +------- 2 files changed, 2 insertions(+), 14 deletions(-) diff --git a/ci/FullMEGA.m b/ci/FullMEGA.m index 98e8660d..45fdab8c 100644 --- a/ci/FullMEGA.m +++ b/ci/FullMEGA.m @@ -1,10 +1,4 @@ -% assume it always fails -exit_code = 1; - % MATLAB runs the test [result,rt] = UnitTest('MEGA',1,1); -% check the result -if sum(rt{1}.Failed) == 0 && sum(rt{1}.Incomplete) == 0 &&sum(rt{2}.Failed) == 0 && sum(rt{2}.Incomplete) == 0 - exit_code = 0; -end \ No newline at end of file +assert(sum(rt{1}.Failed) == 0 && sum(rt{1}.Incomplete) == 0 &&sum(rt{2}.Failed) == 0 && sum(rt{2}.Incomplete) == 0) diff --git a/ci/FullPRESS.m b/ci/FullPRESS.m index 34bbd954..350096d5 100644 --- a/ci/FullPRESS.m +++ b/ci/FullPRESS.m @@ -1,10 +1,4 @@ -% assume it always fails -exit_code = 1; - % MATLAB runs the test [result,rt] = UnitTest('PRESS',1,1); -% check the result -if sum(rt{1}.Failed) == 0 && sum(rt{1}.Incomplete) == 0 &&sum(rt{2}.Failed) == 0 && sum(rt{2}.Incomplete) == 0 - exit_code = 0; -end \ No newline at end of file +assert(sum(rt{1}.Failed) == 0 && sum(rt{1}.Incomplete) == 0 &&sum(rt{2}.Failed) == 0 && sum(rt{2}.Incomplete) == 0) From f08fb58f0cd6e3253888db66d1e886888bdaf40d Mon Sep 17 00:00:00 2001 From: Helge <47348963+HJZollner@users.noreply.github.com> Date: Wed, 21 Jul 2021 14:10:38 -0400 Subject: [PATCH 27/27] Remove unwanted directory [skip ci] [skip ci] --- extdata/ABfit.BASIS | 1 - 1 file changed, 1 deletion(-) delete mode 100644 extdata/ABfit.BASIS diff --git a/extdata/ABfit.BASIS b/extdata/ABfit.BASIS deleted file mode 100644 index 9c8296ff..00000000 --- a/extdata/ABfit.BASIS +++ /dev/null @@ -1 +0,0 @@ - BADELT = 5e-04,