You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Mar 27, 2025. It is now read-only.
Copy file name to clipboardExpand all lines: CONFIGDOC.md
+19-35Lines changed: 19 additions & 35 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -34,68 +34,52 @@ If you need to specify several MATLAB commands, consider writing a MATLAB script
34
34
Test artifacts are not autogenerated if you choose to run tests using this build step. You can generate your desired test artifacts by configuring the test runner in the script or function that you invoke from the **Command** box.
35
35
36
36
## Freestyle Project Setup
37
-
To configure the plugin for a freestyle project, follow these steps:
37
+
To configure the plugin for a freestyle project, specify the location where MATLAB is installed as well as the required build steps.
38
38
39
39
1) In the **Build Environment** section of the project configuration window, select **Use MATLAB Version**. Then, enter the value returned by the **matlabroot** function in the **MATLAB root** box.
* If you add the [**Run MATLAB Tests**](#run-matlab-tests) build step, select check boxes for the artifacts be generated in the project workspace.
45
45
* If you add the [**Run MATLAB Command**](#run-matlab-command) build step, enter your commands in the **Command** box.
46
46
47
47
## Multi-Configuration Project Setup
48
-
In addition to freestyle projects, the Jenkins plugin for MATLAB supports [multi-configuration (matrix) projects](https://wiki.jenkins.io/display/JENKINS/Building+a+matrix+project). Multi-configuration projects are useful when builds include similar steps. For example:
48
+
In addition to freestyle projects, the plugin supports [multi-configuration (matrix) projects](https://wiki.jenkins.io/display/JENKINS/Building+a+matrix+project). Multi-configuration projects are useful when builds include similar steps. For example:
49
49
* The same test suite is run on different platforms (Windows, Linux, and Mac).
50
50
* The same test suite is run using different versions of MATLAB.
51
51
52
-
As in a freestyle project, you can run your tests in automatic or custom mode within a multi-configuration project. The configuration requires you to specify the location where MATLAB is installed as well as the test execution mode. You should also add user-defined axes in the **Configuration Matrix** to specify the duplicating build steps.
52
+
To configure the plugin for a multi-configuration project, specify the location where MATLAB is installed as well as the required build steps. In addition, add user-defined axes in the **Configuration Matrix** section to specify the duplicating build steps.
53
53
54
-
### Run MATLAB Tests
55
-
56
-
To configure the plugin for a matrix build where tests run automatically in multiple MATLAB versions, create a multi-configuration project and follow these steps:
1) Add a user-defined axis in the **Configuration Matrix** to represent the MATLAB versions in the build. Specify the name of the axis in the **Name** field and its values in the **Values** field. Separate the elements in the **Values** field with a space. In this example, four MATLAB versions are specified to run the same set of tests.
1) Add a user-defined axis in the **Configuration Matrix** to represent the MATLAB versions in the build. Specify the name of the axis in the **Name** field and its values in the **Values** field. Separate the elements in the **Values** field with a space. In this example, four MATLAB versions are specified to run the same set of tests.
60
+
Add a user-defined axis in the **Configuration Matrix** to represent the MATLAB versions in the build.
66
61
67
62
68
-
69
-
2) In the **Run MATLAB Tests** section of the project, include the user-defined axis name in the **MATLAB root** field to specify the locations where MATLAB is installed. In this example, **$VERSION** will be replaced by one axis value per build step.
70
-
63
+
Add another user-defined axis using the **Add axis** button. In this example, the **TEST_TAG** axis specifies the possible test tags for a group of test elements.
71
64
72
65
73
-
You can select the test artifact check boxes when tests run automatically. Once you have made your selections, save your settings and run the build.
74
-
75
-
**Note:** Producing a PDF test report is not currently supported on MacOS platforms.
66
+
2) In the **Run MATLAB Tests** section of the project, include the user-defined axis name in the **MATLAB root** field to specify the locations where MATLAB is installed. In this example, **$VERSION** will be replaced by one axis value per build step.
From the **Test mode** drop-down list, select the **Custom** option. Use the second user-defined axis to create your commands and enter them in the **MATLAB command** field. Then, save your settings and run the build.
82
77
83
78
84
-
1) Add a user-defined axis in the **Configuration Matrix** to represent the MATLAB versions in the build.
85
-
86
-
87
-
88
-
2) Add another user-defined axis using the **Add axis** button. In this example, the **TEST_TAG** axis specifies the possible test tags for a group of test elements.
89
-
90
-
91
-
92
-
3) In the **Run MATLAB Tests** section of the project, use the **VERSION** axis to specify the locations where MATLAB is installed.
93
-
94
-
95
-
4) From the **Test mode** drop-down list, select the **Custom** option. Use the second user-defined axis to create your commands and enter them in the **MATLAB command** field. Then, save your settings and run the build.
96
-
79
+
**Note:**
80
+
* For a user-defined axis named **VAR**, **$VAR** and **${VAR}** are both valid formats for accessing the values.
97
81
98
-
**Notes:**
99
-
1) For a user-defined axis named **VAR**, **$VAR** and **${VAR}** are both valid formats for accessing the values.
82
+
* A multi-configuration project creates a separate workspace for each user-defined axis value. If you specify the full paths to where MATLAB is installed as axis values, Jenkins fails to create separate workspaces and fails the build.
100
83
101
-
2) A multi-configuration project creates a separate workspace for each user-defined axis value. If you specify the full paths to where MATLAB is installed as axis values, Jenkins fails to create separate workspaces and fails the build.
84
+
## See Also
85
+
[Run MATLAB Tests on Jenkins Server](/examples/run-matlab-tests.md)
0 commit comments