summaryrefslogtreecommitdiffstats
path: root/Source/cmCTest.cxx
Commit message (Collapse)AuthorAgeFilesLines
* ctest: add option for output truncationFrank Winklmeier2022-03-081-0/+12
| | | | | | | | | | Add `--test-output-truncation` to `ctest`. This option can be used to customize which part of the test output is being truncated. Currently supported values are `tail`, `middle` and `head`. Also add equivalent `CTEST_CUSTOM_TEST_OUTPUT_TRUNCATION` variable. Fixes: #23206
* Refactor: Rename cmCMakePresetsFile to cmCMakePresetsGraphKyle Edwards2022-01-061-17/+17
| | | | And change all references to "file" to say "graph" instead.
* Source: Replace most calls to sprintf with snprintfSean McBride2021-10-251-7/+8
|
* Source: Fix clang -Wimplicit-fallthrough warningsSean McBride2021-09-281-1/+1
|
* Rename cmProp in cmValueMarc Chevrier2021-09-211-7/+7
|
* ctest: add support for attaching files to tests at run timeZack Galbreath2021-06-081-8/+32
| | | | | | | | | | | | | | Allow tests to specify files to upload at runtime. Previously this was only possible to specify at configure time with the ATTACHED_FILES test properties. This commit also fixes a bug in how our test data tarballs were generated by CTest. Previously, if you tried to attach a file outside of the binary directory, CTest would generate a tar file with a relative path, and tar would not allow you to extract it. We resolve this problem by creating tar files with a flat directory structure instead. Fixes: #22284
* CTest: Add env var CLICOLOR to disable color outputMartin Willers2021-05-061-0/+4
| | | | Based on the implementation in Terminal.c:kwsysTerminalStreamIsVT100.
* ctest: Add support for writing test results in JUnit XML formatZack Galbreath2021-04-261-0/+11
| | | | Addresses #18654
* Update CMake code using KWSys to account for Status return valuesBrad King2021-04-141-3/+3
| | | | | | KWSys as of 2021-04-14 changed the return type of `SystemTools` operations from `bool` to `Status`. Update our call sites. This may improve error reporting accuracy in a few places.
* ctest: Support multiple -L and -LE options to mean "AND"Adriaan de Groot2021-03-281-10/+19
| | | | Fixes: #21087
* CMakePresets.json: Add the ability to conditionally disable presetsKyle Edwards2021-03-221-0/+7
|
* Source: Reduce c_str() usagevvs314152021-03-131-3/+3
|
* ctest: Add support for '--prefix=<prefix>' form of the argumentBrad King2021-02-231-2/+8
| | | | | | | The main `cmake --preset` argument for configure presets supports both forms, so support it for `ctest --preset` too. Fixes: #21855
* presets: Remove unintended rerunFailed option from test presetsSam Freed2021-02-151-5/+0
| | | | | | | This was accidentally included after discussion in #21391 had decided to leave it out. It was never included in a release. Issue: #21391
* cmake-presets: Add build and test presetsSam Freed2021-02-011-1/+339
| | | | Fixes: #21391
* Merge topic 'ctest-progress-output-fixes'Brad King2021-01-071-1/+1
|\ | | | | | | | | | | | | | | 39cdc8afb9 ctest: Make verbose mode override progress behavior 1bcd9b06b9 ctest: Don't treat skipped test as failed tests in progess report Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !5663
| * ctest: Make verbose mode override progress behaviorSylvain Joubert2021-01-051-1/+1
| | | | | | | | | | Start and results should now be back in verbose mode even with progress mode enabled.
* | Code style: add missed explicit 'this->'Oleksandr Koval2021-01-051-2/+2
|/ | | | | CMake uses explicit 'this->' style. Using custom clang-tidy check we can detect and fix places where 'this->' was missed.
* Ctest: Support build tree on command lineAsit Dhal2020-12-171-2/+33
| | | | Fixes: #21268
* ctest: Provide hints about inspecting test failuresAsit Dhal2020-12-011-0/+11
| | | | Fixes: #20955
* cmMakefile::GetDefinition: return cmPropVitaly Stakhovsky2020-09-021-5/+5
|
* CTest: exit nonzero after message(SEND_ERROR|FATAL_ERROR)Kevin Puetz2020-08-261-2/+1
| | | | Fixes: #21004
* cmCTest: Members accept std::string parametersVitaly Stakhovsky2020-07-271-38/+33
|
* cmCTest: Explicitly specify '.tmp' extension on in-progress log filesBrad King2020-07-081-0/+1
| | | | Do not depend on `cmGeneratedFileStream` to have this default.
* Single location for cmProp typedefVitaly Stakhovsky2020-06-011-0/+1
|
* Refactoring: Third-parties public headers are under cm3p prefixMarc Chevrier2020-05-071-3/+3
| | | | Fixes: #20666
* Refactoring: rename "cm_static_string_view.hxx" as <cmext/string_view>Marc Chevrier2020-04-301-2/+1
|
* ctest: add option --stop-on-failureJohnny Jazeix2020-04-201-0/+15
| | | | | | To stop the tests once one has failed Fixes: #16628
* clang-tidy: address bugprone-branch-clone lintsBen Boeckel2020-04-131-7/+5
| | | | | | | | | Arguably, many of these are bugs in `clang-tidy`. An if/else tree with other conditionals between cloned blocks may be relying on the intermediate logic to fall out of the case and inverting this logic may be non-trivial. See: https://bugs.llvm.org/show_bug.cgi?id=44165
* Merge topic 'cmprop-getglobalprop'Brad King2020-03-271-7/+6
|\ | | | | | | | | | | | | c84cf42897 cmState::GetGlobalProperty: return cmProp Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !4521
| * cmState::GetGlobalProperty: return cmPropVitaly Stakhovsky2020-03-251-7/+6
| |
* | use _s to construct static string_views at several placesRolf Eike Beer2020-03-241-62/+67
| | | | | | | | This should avoid the runtime strlen() call.
* | use string_views to avoid memory allocationsRolf Eike Beer2020-03-241-3/+6
| |
* | replace std::string::substr() with operations that do not allocate memoryRolf Eike Beer2020-03-231-2/+2
| | | | | | | | | | Modify the original string instead of creating a new copy with substr() when it is not used for anything else afterwards.
* | replace "std::string::find(x) == 0" with cmHasPrefix()Rolf Eike Beer2020-03-231-1/+1
| |
* | allow cmCTest::CleanString() to skip input charactersRolf Eike Beer2020-03-231-3/+4
| | | | | | | | | | This entirely avoids that one needs to call std::string::substr() for the input.
* | CTest: avoid repeated string comparesRolf Eike Beer2020-03-231-80/+63
|/ | | | | | Only one key can match per iteration, avoid any further compares when one match was already found. While at it entirely avoid that the key and value strings are copied.
* Modernize memory managementMarc Chevrier2020-02-271-13/+8
| | | | Update internals of various classes
* Add --no-tests=<[error|ignore]> option to CTestStefan Dinkelacker2020-01-311-0/+20
| | | | | | | | | If no tests were found, the default behavior of CTest is to always log an error message but to return an error code in script mode only. This option unifies the behavior of CTest by either returning an error code if no tests were found or by ignoring it. Signed-off-by: Stefan Dinkelacker <s.dinkelacker@dkfz-heidelberg.de>
* Refactoring: use append functions from cmext/algorithmMarc Chevrier2019-12-171-5/+5
|
* CTest: Consolidate '--repeat-* n' options as `--repeat *:n`Brad King2019-11-151-34/+24
| | | | | | | Combine `--repeat-until-fail`, `--repeat-until-pass`, and `--repeat-after-timeout` to create a single `--repeat <mode>:<n>` option. Retain `--repeat-until-fail` too because that has been available in previous releases.
* CTest: Rename internal APIs for --repeat optionsBrad King2019-11-071-15/+15
| | | | Replace use of the term "rerun" with "repeat" to match the public names.
* Merge branch 'backport-ctest-resource-groups'Brad King2019-11-051-3/+3
|\
| * CTest: Rename hardware -> resources for CMake variables, command optionsCraig Scott2019-11-051-3/+3
| | | | | | | | | | | | Only changes the user-visible effects of renaming hardware allocation to resource allocation. Code changes are the minimum needed to achieve that.
* | ctest: Add --repeat-after-timeout optionBrad King2019-10-291-0/+22
| | | | | | | | | | Add an option to re-run tests if they timeout. This will help tolerate sporadic timeouts on busy machines.
* | ctest: Add --repeat-until-pass optionBrad King2019-10-291-4/+31
|/ | | | | | | | | Add an option to re-run tests if they fail. This will help tolerate sporadic failures. Issue: #17010 Co-Author: Ben Boeckel <ben.boeckel@kitware.com> Co-Author: Chuck Atkins <chuck.atkins@kitware.com>
* CTest: Allocate hardware to testsKyle Edwards2019-10-021-0/+9
|
* Revise include order using clang-format-6.0Kitware Robot2019-10-011-8/+10
| | | | | Run the `clang-format.bash` script to update our C and C++ code to a new include order `.clang-format`. Use `clang-format` version 6.0.
* cmstd: Modernize CMake system headersMarc Chevrier2019-09-201-1/+1
| | | | | | | | | | | | | | Provide a standardized way to handle the C++ "standard" headers customized to be used with current CMake C++ standard constraints. Offer under directory `cm` headers which can be used as direct replacements of the standard ones. For example: #include <cm/string_view> can be used safely for CMake development in place of the `<string_view>` standard header. Fixes: #19491
* clang-tidy: modernize-deprecated-headersRegina Pfeifer2019-09-161-5/+5
|