6#include <range/v3/algorithm/transform.hpp>
7#include <range/v3/range/conversion.hpp>
8#include <range/v3/view/transform.hpp>
25 Assignment(std::string_view name, std::filesystem::path exec_path)
noexcept;
27 void add_test(std::unique_ptr<TestBase> test)
const noexcept;
29 std::string_view
get_name() const noexcept {
return name_; }
31 std::filesystem::path
get_exec_path() const noexcept {
return exec_path_; }
33 void set_exec_path(std::filesystem::path path)
noexcept { exec_path_ = std::move(path); }
36 return tests_ | ranges::views::transform([](std::unique_ptr<TestBase>& test) ->
TestBase& {
return *test; });
41 ranges::views::transform([](
const std::unique_ptr<TestBase>& test) {
return test->get_name(); }) |
42 ranges::to<std::vector>();
46 std::string_view name_;
47 std::filesystem::path exec_path_;
49 mutable std::vector<std::unique_ptr<TestBase>> tests_;
Declaration for the logic and data encapsulating a class assignment.
Definition assignment.hpp:23
void add_test(std::unique_ptr< TestBase > test) const noexcept
Definition assignment.cpp:16
void set_exec_path(std::filesystem::path path) noexcept
Definition assignment.hpp:33
std::string_view get_name() const noexcept
Definition assignment.hpp:29
std::vector< std::string_view > get_test_names() const noexcept
Definition assignment.hpp:39
std::filesystem::path get_exec_path() const noexcept
Definition assignment.hpp:31
Assignment(std::string_view name, std::filesystem::path exec_path) noexcept
Definition assignment.cpp:12
auto get_tests() const noexcept
Definition assignment.hpp:35
A trivially-movable, but non-copyable type.
Definition class_traits.hpp:14
Base class primarily for a user-written test.
Definition test_base.hpp:17
Definition asm_buffer.hpp:19