See also
Please make sure to read Unit Testing guide first.
test_filter
¶Type: String (Pattern)
| Multiple: Yes
Process only the Unit Testing tests where the name matches specified patterns.
Also, you can filter some tests using platformio test --filter
command.
Pattern |
Meaning |
---|---|
|
matches everything |
|
matches any single character |
|
matches any character in seq |
|
matches any character not in seq |
Example
[env:myenv]
test_filter = footest, bartest_*, test[13]
test_ignore
¶Type: String (Pattern)
| Multiple: Yes
Ignore Unit Testing tests where the name matches specified patterns.
Also, you can ignore some tests using platformio test --ignore
command.
Pattern |
Meaning |
---|---|
|
matches everything |
|
matches any single character |
|
matches any character in seq |
|
matches any character not in seq |
Example
[env:myenv]
test_ignore =
footest
bartest_*
test[13]
test_port
¶Type: String (Pattern)
| Multiple: No
This option specifies communication interface (Serial/UART) between PlatformIO Unit Testing Engine and target device. For example,
/dev/ttyUSB0
- Unix-based OS
COM3
- Windows OS
If test_port
isn’t specified, then PlatformIO will try to detect it
automatically.
To print all available serial ports use platformio device list command.
test_speed
¶Type: Integer
| Multiple: No
| Default: 115200
A connection speed (baud rate) to communicate with a target device.
test_transport
¶Type: String
| Multiple: No
A transport type which will be used to read test results from a target device. See more details at Test Transport.
test_build_project_src
¶Type: Bool (yes or no)
| Multiple: No
| Default: no
Force Unit Testing engine to build project source code from
src_dir setting test_build_project_src
to yes
.
More detail about Shared Code.
Example
[env:myenv]
platform = ...
test_build_project_src = yes