@@ -12,32 +12,41 @@ jobs:
1212
1313 strategy :
1414 matrix :
15- matlab_version : [R2023a]
16- os : [windows-latest]
17- fail-fast : false
15+ # Note that some older versions (e.g R2020a, R2020b...) may not be available on all OS
16+ matlab_version : [R2022a, R2022b, R2023a, R2023b]
17+ os : [ubuntu-latest, macos-latest, windows-latest]
18+ fail-fast : false # Don't cancel all jobs if one fails
1819
1920 runs-on : ${{ matrix.os }}
2021
2122 steps :
2223
23- # use matlab-actions/setup-matlab to setup a specific version of MATLAB
24- # https://github.com/matlab-actions/setup-matlab
24+ # use matlab-actions/setup-matlab to setup a specific version of MATLAB
25+ # https://github.com/matlab-actions/setup-matlab
2526 - name : Install MATLAB
26- uses : matlab-actions/setup-matlab@v1.2.4
27+ uses : matlab-actions/setup-matlab@v2
2728 with :
2829 release : ${{ matrix.matlab_version }}
2930
3031 - name : Checkout repository
31- uses : actions/checkout@v3
32+ uses : actions/checkout@v4
3233
3334 - name : Install Moxunit
34- run : |
35- git clone https://github.com/MOxUnit/MOxUnit.git --depth 1
35+ run : git clone https://github.com/MOxUnit/MOxUnit.git --depth 1
3636
37- # use matlab-actions/setup-matlab to run a matlab command
38- # https://github.com/matlab-actions/setup-matlab
37+ # use matlab-actions/setup-matlab to run a matlab command
38+ # https://github.com/matlab-actions/setup-matlab
3939 - name : Run tests on dummy source code to test MoCov
40- uses : matlab-actions/run-command@v1.1.3
40+ uses : matlab-actions/run-command@v2
4141 with :
4242 command : cd('./MOxUnit/MOxUnit/'); moxunit_set_path(); cd ../..; addpath(fullfile(pwd, 'MOcov')); moxunit_runtests tests -verbose -recursive
4343 -with_coverage -cover tests/regression/src -cover_xml_file coverage.xml; exit(double(~ans))
44+
45+ - name : Code coverage
46+ uses : codecov/codecov-action@v5
47+ with :
48+ files : coverage.xml
49+ flags : ${{ matrix.os }}_matlab-${{ matrix.matlab_version }}
50+ name : codecov-matlab
51+ fail_ci_if_error : false
52+ token : ${{ secrets.CODECOV_TOKEN }}
0 commit comments