Manage Test File Dependencies

You can help track and manage your test file dependencies by creating a project for your test file and the files it depends on. Examples of test file dependencies include requirements, data files, callbacks, test harnesses, and custom criteria scripts. Packaging test file dependencies in a project also helps you share tests with other users.

Package a Test File Using Projects

  1. In the Test Browser, right-click the test file.

  2. Select Project > Create Project from Test File.

    Project opens and identifies the file dependencies of the test file. In this example, the test file contains a test case with a requirements link, an input file, and a baseline file.

  3. Specify project name, and verify the list of selected file dependencies.

  4. Click Create.

Find Test File Dependencies and Impact

You can find test file dependencies from the Test Browser. Your test file must be saved in a Simulink® project.

  1. Right-click the test file. Select Project > Find Dependencies.

    Dependencies are color coded in the file dependency graph.

If you want to change a model or requirement, you can determine the potential impact of the change on your tests.

  1. In the dependency graph, select the item that could impact your tests.

  2. In the Project toolstrip, click Files > Files Impacted by Selection.

If you want to run a test file again, then you can right-click the test file in the graph and select Run. The Test Manager opens the test file and runs the test cases contained in it.

Share a Test File with Dependencies

You can easily share test files that are already saved in a project. If you send the project folder, it contains the file dependencies for the test file.

Related Topics