Sequoia
Loading...
Searching...
No Matches
TestRunnerTest.hpp
Go to the documentation of this file.
1
2// Copyright Oliver J. Rosten 2021. //
3// Distributed under the GNU GENERAL PUBLIC LICENSE, Version 3.0. //
4// (See accompanying file LICENSE.md or copy at //
5// https://www.gnu.org/licenses/gpl-3.0.en.html) //
7
8#pragma once
9
13
14namespace sequoia::testing
15{
16 class test_runner;
17
18 class test_runner_test final : public free_test
19 {
20 public:
21 using free_test::free_test;
22
23 [[nodiscard]]
24 std::filesystem::path source_file() const;
25
26 void run_tests();
27 private:
28
29 void test_exceptions();
30
31 void test_critical_errors();
32
33 void test_filtered_suites();
34
35 void test_basic_output();
36
37 void test_verbose_output();
38
39 void test_serial_verbose_output();
40
41 void test_throwing_tests();
42
43 void test_prune_basic_output();
44
45 void test_nested_suite();
46
47 void test_nested_suite_verbose();
48
49 void test_instability_analysis();
50
51 template<std::invocable<test_runner&> Manipulator, concrete_test... Ts>
52 void test_instability_analysis(std::string_view message,
53 std::string_view outputDirName,
54 std::string_view numRuns,
55 std::initializer_list<std::string_view> extraArgs,
56 Manipulator manipulator,
57 Ts&&... ts);
58
59 template<concrete_test... Ts>
60 void test_instability_analysis(std::string_view message,
61 std::string_view outputDirName,
62 std::string_view numRuns,
63 std::initializer_list<std::string_view> extraArgs,
64 Ts&&... ts);
65
66 template<concrete_test... Ts>
67 void test_instability_analysis(std::string_view message,
68 std::string_view outputDirName,
69 std::string_view numRuns,
70 Ts&&... ts);
71
72 [[nodiscard]]
73 std::filesystem::path fake_project() const;
74
75 [[nodiscard]]
76 std::filesystem::path minimal_fake_path() const;
77
78 [[nodiscard]]
79 std::string zeroth_arg() const;
80
81 void write(std::string_view dirName, std::stringstream& output) const;
82
83 void check_output(reporter description, std::string_view dirName, std::stringstream& output);
84 };
85}
Core functionality for the testing framework.
class template from which all concrete tests should derive.
Definition: FreeTestCore.hpp:144
Definition: Output.hpp:186
Definition: TestRunnerTest.hpp:19
Definition: FreeTestCore.hpp:189