File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11# Run tInstall on Ubuntu against python versions 3.10, 3.9 and 3.8
22
3- name : Test R2022b and R2023a
4-
3+ name : Test R2022b
54on :
65 push :
76 branches :
87 - R2022b
9- - R2023a
10- - main
8+
9+ pull_request :
10+ branches :
11+ - R2022b
1112
1213 # Allows you to run this workflow manually from the Actions tab
1314 workflow_dispatch :
2021 strategy :
2122 matrix :
2223 python : ["3.10", "3.9", "3.8"]
23- matlab : [R2022b, R2023a]
2424
2525 runs-on : ubuntu-latest
2626
3333 - name : Set up MATLAB
3434 uses : matlab-actions/setup-matlab@v1
3535 with :
36- release : ${{ matrix.matlab }}
36+ release : R2022b
3737
3838 - uses : actions/checkout@v3
3939
Original file line number Diff line number Diff line change 55
66 properties (Constant )
77 MATLABVersion = string(ver(' MATLAB' ).Version) % Example: 9.14
8- MATLABRelease = erase(ver(' MATLAB' ).Release,{' (' ,' )' }) % Example: (R2023a) -> R2023a
98 end
109
1110 methods (Test )
12- function installNoVersionSpecified(testCase )
13- assumeEqual(testCase , testCase .MATLABRelease , ' R2023a' )
14- [status , out ] = system(" pip install matlabengine" );
15- verifyEqual(testCase , status , 0 , out )
16- verifyInstallation(testCase )
17- end
18-
1911 function installMatchingEngine(testCase )
2012 [status , out ] = system(" pip install matlabengine==" + testCase .MATLABVersion + " .*" );
13+ addTeardown(testCase , @system , " pip uninstall -y matlabengine" )
2114 verifyEqual(testCase , status , 0 , out )
2215 verifyInstallation(testCase )
2316 end
@@ -34,7 +27,6 @@ function verifyInstallation(testCase)
3427 end
3528 pySharedEngineName = string(py .matlab .engine .find_matlab());
3629 verifyEqual(testCase , pySharedEngineName , sharedEngineName )
37- system(" pip uninstall -y matlabengine" )
3830 end
3931 end
4032end
You can’t perform that action at this time.
0 commit comments