mirror of
https://github.com/platformio/platformio-core.git
synced 2025-07-31 02:27:13 +02:00
Refactor "test_ignore" to accepts test names separated with comma // Resolve #753
This commit is contained in:
@ -802,9 +802,9 @@ Test options
|
||||
.. seealso::
|
||||
Please make sure to read :ref:`unit_testing` guide first.
|
||||
|
||||
Ignore tests where the name matches specified patterns.
|
||||
More than one pattern is allowed (multi-lines). Also, you can ignore some
|
||||
tests using :option:`platformio test --ignore` command.
|
||||
Ignore tests where the name matches specified patterns. Multiple names are
|
||||
allowed. Please separate them using comma ``,`` symbol. Also, you can
|
||||
ignore some tests using :option:`platformio test --ignore` command.
|
||||
|
||||
.. list-table::
|
||||
:header-rows: 1
|
||||
@ -829,9 +829,7 @@ tests using :option:`platformio test --ignore` command.
|
||||
.. code-block:: ini
|
||||
|
||||
[env:myenv]
|
||||
test_ignore =
|
||||
mytest*
|
||||
test[13]
|
||||
test_ignore = footest, bartest_*, test[13]
|
||||
|
||||
-----------
|
||||
|
||||
|
@ -72,7 +72,7 @@ def cli(ctx, environment, ignore, upload_port, project_dir, verbose):
|
||||
if projectconf.has_option(section, "test_ignore"):
|
||||
_ignore.extend([p.strip()
|
||||
for p in projectconf.get(
|
||||
section, "test_ignore").split("\n")
|
||||
section, "test_ignore").split(",")
|
||||
if p.strip()])
|
||||
if testname != "*" and \
|
||||
any([fnmatch(testname, p) for p in _ignore]):
|
||||
|
Reference in New Issue
Block a user