Include paths for external tests
Specify paths to folders containing include files for external tests
Since R2023b
Description
External tests are developed using a supported third-party framework. Specify paths to
the folder(s) in which Polyspace®
Test™ looks for the header files included with #include
statements in the external tests. You can specify either a relative path or an absolute
path to the include files.
Set Option
In your Polyspace Platform project configuration, on the Build tab, select the External Tests node and then enter include folder paths for this option.
Why Use This Option
In Polyspace
Test, you can add external tests that use a supported third-party framework,
such as GoogleTest. These tests might require header files specific
to the framework. Use this option to specify the locations of header files for such
external tests. Polyspace
Test searches for the required header files in these locations.
Settings
Specify the relative or absolute path to the folders that contains your header files. To add a folder:
Click
and enter the path to the folder containing your header files.
Polyspace resolves the relative paths relative to the location of the project
file (*.psprjx).Alternatively, you can browse to the location by using the Add folder(
) or Add folder as relative
path(
) button.
If you want to include the subfolders of the specified folder recursively, select the checkbox in the Subfolders column.
Tips
You can use system environment variables as shorthands in the include folder paths. If you share the project with another user who has the include folders in a different root location, utilizing environment variables can help ensure that the project stays in sync with include folder paths. For more information, see:
Command-Line Information
The command-line workflow for setting this option depends on your workflow.
If you build your source and tests using a Polyspace Platform Project — Once you set this option in the project using the Polyspace Platform user interface, you cannot override or modify this option using the
polyspace-testcommand.If you build your sources and xUnit tests using your own toolchain — You might be able to provide include paths directly to your compiler as part of your build command. For instance, if you use
gcc, use the option-Ito specify include paths during command line compilation.
Version History
Introduced in R2023b