mirror of
https://github.com/platformio/platformio-core.git
synced 2025-07-30 01:57:13 +02:00
Rename pio test --output-{format} options to --{format}-output
This commit is contained in:
2
docs
2
docs
Submodule docs updated: 4522b6d963...8acef5b3a2
@ -83,8 +83,8 @@ from platformio.test.runners.factory import TestRunnerFactory
|
|||||||
multiple=True,
|
multiple=True,
|
||||||
help="A program argument (multiple are allowed)",
|
help="A program argument (multiple are allowed)",
|
||||||
)
|
)
|
||||||
@click.option("--output-json", type=click.Path(resolve_path=True))
|
@click.option("--json-output", type=click.Path(resolve_path=True))
|
||||||
@click.option("--output-junit", type=click.Path(resolve_path=True))
|
@click.option("--junit-output", type=click.Path(resolve_path=True))
|
||||||
@click.option("--verbose", "-v", is_flag=True)
|
@click.option("--verbose", "-v", is_flag=True)
|
||||||
@click.pass_context
|
@click.pass_context
|
||||||
def test_cmd( # pylint: disable=too-many-arguments,too-many-locals,redefined-builtin
|
def test_cmd( # pylint: disable=too-many-arguments,too-many-locals,redefined-builtin
|
||||||
@ -103,8 +103,8 @@ def test_cmd( # pylint: disable=too-many-arguments,too-many-locals,redefined-bu
|
|||||||
monitor_rts,
|
monitor_rts,
|
||||||
monitor_dtr,
|
monitor_dtr,
|
||||||
program_args,
|
program_args,
|
||||||
output_json,
|
json_output,
|
||||||
output_junit,
|
junit_output,
|
||||||
verbose,
|
verbose,
|
||||||
):
|
):
|
||||||
app.set_session_var("custom_project_conf", project_conf)
|
app.set_session_var("custom_project_conf", project_conf)
|
||||||
@ -177,7 +177,7 @@ def test_cmd( # pylint: disable=too-many-arguments,too-many-locals,redefined-bu
|
|||||||
stdout_report = TestReportFactory.new("stdout", test_result)
|
stdout_report = TestReportFactory.new("stdout", test_result)
|
||||||
stdout_report.generate(verbose=verbose)
|
stdout_report.generate(verbose=verbose)
|
||||||
|
|
||||||
for output_format, output_path in [("json", output_json), ("junit", output_junit)]:
|
for output_format, output_path in [("json", json_output), ("junit", junit_output)]:
|
||||||
if not output_path:
|
if not output_path:
|
||||||
continue
|
continue
|
||||||
custom_report = TestReportFactory.new(output_format, test_result)
|
custom_report = TestReportFactory.new(output_format, test_result)
|
||||||
|
@ -36,7 +36,7 @@ def test_calculator_example(tmp_path: Path):
|
|||||||
"uno",
|
"uno",
|
||||||
"-e",
|
"-e",
|
||||||
"native",
|
"native",
|
||||||
"--output-junit",
|
"--junit-output",
|
||||||
str(junit_output_path),
|
str(junit_output_path),
|
||||||
]
|
]
|
||||||
)
|
)
|
||||||
@ -526,7 +526,7 @@ int main(int argc, char **argv)
|
|||||||
[
|
[
|
||||||
"-d",
|
"-d",
|
||||||
str(project_dir),
|
str(project_dir),
|
||||||
"--output-junit",
|
"--junit-output",
|
||||||
str(junit_output_path),
|
str(junit_output_path),
|
||||||
],
|
],
|
||||||
)
|
)
|
||||||
@ -551,7 +551,7 @@ int main(int argc, char **argv)
|
|||||||
[
|
[
|
||||||
"-d",
|
"-d",
|
||||||
str(project_dir),
|
str(project_dir),
|
||||||
"--output-json",
|
"--json-output",
|
||||||
str(json_output_path),
|
str(json_output_path),
|
||||||
"-a",
|
"-a",
|
||||||
"-aa=1", # fail after the 1 error
|
"-aa=1", # fail after the 1 error
|
||||||
@ -575,7 +575,7 @@ def test_googletest_framework(clirunner, tmp_path: Path):
|
|||||||
project_dir,
|
project_dir,
|
||||||
"-e",
|
"-e",
|
||||||
"native",
|
"native",
|
||||||
"--output-junit",
|
"--junit-output",
|
||||||
str(junit_output_path),
|
str(junit_output_path),
|
||||||
],
|
],
|
||||||
)
|
)
|
||||||
@ -602,7 +602,7 @@ def test_googletest_framework(clirunner, tmp_path: Path):
|
|||||||
project_dir,
|
project_dir,
|
||||||
"-e",
|
"-e",
|
||||||
"native",
|
"native",
|
||||||
"--output-json",
|
"--json-output",
|
||||||
str(json_output_path),
|
str(json_output_path),
|
||||||
"-a",
|
"-a",
|
||||||
"--gtest_filter=-FooTest.Bar",
|
"--gtest_filter=-FooTest.Bar",
|
||||||
|
Reference in New Issue
Block a user