|
KiCad PCB EDA Suite
|
#include <boost/test/unit_test.hpp>#include <gestfich.h>#include <wx/process.h>#include <wx/txtstrm.h>#include <wx/filename.h>#include <wx/dir.h>#include <wx/file.h>Go to the source code of this file.
Functions | |
| static int | executeViaShell (const wxString &aCmd, wxString &aOutput) |
| Drive the production ExecuteCommandThroughShell (the exact function jobsets use) and capture its stdout so the shell-wrapping behaviour is tested directly rather than through a copy. | |
| BOOST_AUTO_TEST_CASE (SimpleCommand) | |
| BOOST_AUTO_TEST_CASE (GlobExpansion) | |
| BOOST_AUTO_TEST_CASE (PipeSupport) | |
| BOOST_AUTO_TEST_CASE (ExitCodePropagation) | |
| BOOST_AUTO_TEST_CASE (CommandWithSingleQuotes) | |
| BOOST_AUTO_TEST_CASE (AbsolutePathWithSpaces) | |
| Regression for https://gitlab.com/kicad/code/kicad/-/issues/24226. | |
| BOOST_AUTO_TEST_CASE | ( | AbsolutePathWithSpaces | ) |
Regression for https://gitlab.com/kicad/code/kicad/-/issues/24226.
An absolute path containing spaces, quoted by the user, must reach the interpreter intact. The old array-form invocation on Windows let wxExecute backslash-escape the quotes and cmd.exe then mangled the path. Run an interpreter located at a spaced absolute path against a script that prints a sentinel and verify the sentinel comes back.
Definition at line 202 of file test_jobs_runner.cpp.
References BOOST_CHECK_EQUAL(), BOOST_CHECK_MESSAGE(), BOOST_REQUIRE(), executeViaShell(), output, and result.
| BOOST_AUTO_TEST_CASE | ( | CommandWithSingleQuotes | ) |
Definition at line 159 of file test_jobs_runner.cpp.
References BOOST_CHECK_EQUAL(), BOOST_CHECK_MESSAGE(), executeViaShell(), output, and result.
| BOOST_AUTO_TEST_CASE | ( | ExitCodePropagation | ) |
Definition at line 144 of file test_jobs_runner.cpp.
References BOOST_CHECK_EQUAL(), executeViaShell(), output, and result.
| BOOST_AUTO_TEST_CASE | ( | GlobExpansion | ) |
Definition at line 86 of file test_jobs_runner.cpp.
References BOOST_CHECK_EQUAL(), BOOST_CHECK_MESSAGE(), BOOST_REQUIRE(), executeViaShell(), output, and result.
| BOOST_AUTO_TEST_CASE | ( | PipeSupport | ) |
Definition at line 128 of file test_jobs_runner.cpp.
References BOOST_CHECK_EQUAL(), executeViaShell(), output, and result.
| BOOST_AUTO_TEST_CASE | ( | SimpleCommand | ) |
Definition at line 73 of file test_jobs_runner.cpp.
References BOOST_CHECK_EQUAL(), executeViaShell(), output, and result.
|
static |
Drive the production ExecuteCommandThroughShell (the exact function jobsets use) and capture its stdout so the shell-wrapping behaviour is tested directly rather than through a copy.
Definition at line 42 of file test_jobs_runner.cpp.
References ExecuteCommandThroughShell(), executeViaShell(), process, and result.
Referenced by BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), and executeViaShell().