Skip to content

Commit f475a71

Browse files
committed
Maintenance of Live Modules Update for 2024b+.
- Updated CI - Updated Smoke Tests - Plotting hard-coded color updates - Project structure updates - Added Instructor Solutions
1 parent f0c02c2 commit f475a71

176 files changed

Lines changed: 934 additions & 369 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/ci.yml

Lines changed: 60 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,73 +1,109 @@
1-
name: Module Test
1+
name: MATLAB Build
22

33
# Controls when the action will run.
44
on:
55
push:
66
branches: [ release ]
77
pull_request:
88
branches: [ release ]
9+
workflow_dispatch:
10+
11+
# Add permission to write GitHub pages
12+
permissions:
13+
contents: write
14+
pages: write
15+
id-token: write
916

1017
jobs:
11-
RunTests:
18+
test:
1219
strategy:
1320
fail-fast: false
1421
matrix:
15-
MATLABVersion: [R2024a]
22+
MATLABVersion: [R2024a,R2024b]
1623
runs-on: ubuntu-latest
1724
steps:
1825
# Checks-out your repository
19-
- uses: actions/checkout@v3
26+
- uses: actions/checkout@v4
27+
28+
# Sets up a display server
29+
- name: Start display server
30+
if: ${{ always() }}
31+
run: |
32+
sudo apt-get install xvfb
33+
Xvfb :99 &
34+
echo "DISPLAY=:99" >> $GITHUB_ENV
2035
2136
# Sets up MATLAB
2237
- name: Setup MATLAB
23-
uses: matlab-actions/setup-matlab@v1
38+
uses: matlab-actions/setup-matlab@v2
2439
with:
2540
release: ${{ matrix.MATLABVersion }}
41+
products: MATLAB Simulink Simscape DSP_System_Toolbox Simscape_Electrical
42+
# List required products above in the format shown (and uncomment them)
43+
# List of product strings:
44+
# Simulink
45+
# Statistics_and_Machine_Learning_Toolbox
46+
# Simulink_Coder
47+
# Econometrics_Toolbox
48+
# Deep_Learning_Toolbox
49+
2650

2751
# Run all the tests
2852
- name: Run SmokeTests
29-
uses: matlab-actions/run-command@v1
53+
uses: matlab-actions/run-command@v2
3054
with:
3155
command: openProject(pwd); RunAllTests;
3256

3357
# Upload the test results as artifact
3458
- name: Upload TestResults
35-
if: always()
36-
uses: actions/upload-artifact@v3.1.3
59+
if: ${{ always() }}
60+
uses: actions/upload-artifact@v4
3761
with:
38-
name: TestResults
39-
path: ./SoftwareTests/TestResults_${{ matrix.MATLABVersion }}.txt
62+
name: TestResults_${{ matrix.MATLABVersion }}
63+
path: ./public/*
64+
overwrite: true
4065

41-
42-
CreateBadge:
66+
badge:
4367
if: ${{ always() }}
44-
needs: [RunTests]
68+
needs: [test]
4569
strategy:
4670
fail-fast: false
4771
runs-on: ubuntu-latest
4872
steps:
4973

5074
# Checks-out your repository
51-
- uses: actions/checkout@v3
75+
- uses: actions/checkout@v4
5276

5377
# Sets up R2023b
5478
- name: Setup MATLAB
55-
uses: matlab-actions/setup-matlab@v1
79+
uses: matlab-actions/setup-matlab@v2
5680
with:
57-
release: R2023b
81+
release: R2024b
5882

5983
# Download the test results from artifact
60-
- name: Download TestResults
61-
uses: actions/download-artifact@v2.1.1
84+
- name: Download All TestResults
85+
uses: actions/download-artifact@v4
6286
with:
63-
name: TestResults
64-
path: ./SoftwareTests/
65-
87+
path: public
88+
pattern: TestResults_*
89+
merge-multiple: true
90+
6691
# Create the test results badge
67-
- name: Run CreateBadge
68-
uses: matlab-actions/run-command@v1
92+
- name: Run PostSmokeTest
93+
uses: matlab-actions/run-command@v2
94+
with:
95+
command: openProject(pwd); PostSmokeTest;
96+
97+
# Deploy reports to GitHub pages
98+
- name: Setup Pages
99+
uses: actions/configure-pages@v5
100+
- name: Upload pages artifact
101+
uses: actions/upload-pages-artifact@v3
69102
with:
70-
command: openProject(pwd); CreateBadge;
103+
path: public
104+
- name: Deploy to GitHub Pages
105+
id: deployment
106+
uses: actions/deploy-pages@v4
71107

72108
# Commit the JSON for the MATLAB releases badge
73109
- name: Commit changed files

.gitignore

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,5 +47,5 @@ codegen/
4747
# Project settings
4848
Utilities/ProjectSettings.mat
4949

50-
# Test results
51-
SoftwareTests/TestResults_*
50+
# GitLab page folder
51+
public/

Images/TestedWith.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
{"schemaVersion":1,"label":"Tested with","color":"success","message":"R2024a"}
1+
{"schemaVersion":1,"label":"Tested with","color":"success","message":"R2024a | R2024b"}

Images/input1.png

2.36 KB
Loading

Images/output.png

3.87 KB
Loading
76.7 KB
Binary file not shown.
133 KB
Binary file not shown.
84.1 KB
Binary file not shown.
102 KB
Binary file not shown.
179 KB
Binary file not shown.

0 commit comments

Comments
 (0)