Skip to content

Commit 40a4d6b

Browse files
committed
Beman Standard: Apply [DIRECTORY.TESTS]
1 parent 6311b0d commit 40a4d6b

12 files changed

+27
-24
lines changed

CMakeLists.txt

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,10 +46,13 @@ if(OPTIONAL_ENABLE_TESTING)
4646
add_executable(beman_optional_test)
4747
target_sources(
4848
beman_optional_test
49-
PRIVATE FILE_SET beman_optional_test_headers TYPE HEADERS BASE_DIRS src
49+
PRIVATE
50+
FILE_SET beman_optional_test_headers
51+
TYPE HEADERS
52+
BASE_DIRS tests
5053
)
5154

52-
add_subdirectory(src/beman/optional/tests)
55+
add_subdirectory(tests/beman/optional)
5356
endif()
5457

5558
add_subdirectory(include/beman/optional)

src/beman/optional/tests/detail/iterator.t.cpp renamed to tests/beman/optional/detail/iterator.t.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// src/beman/optional/tests/detail/iterator.t.cpp -*-C++-*-
1+
// tests/beman/optional/detail/iterator.t.cpp -*-C++-*-
22
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
33

44
/**
@@ -7,7 +7,7 @@
77
#include <beman/optional/detail/iterator.hpp>
88

99
#include <gtest/gtest.h>
10-
#include <tests/test_types.hpp>
10+
#include <beman/optional/test_types.hpp>
1111

1212
#include <concepts>
1313
#include <cstdlib>
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
1-
// src/beman/optional/tests/optional.t.cpp -*-C++-*-
1+
// tests/beman/optional/optional.t.cpp -*-C++-*-
22
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
33

44
#include <beman/optional/optional.hpp>
55

66
#include <beman/optional/optional.hpp> // test 2nd include OK
77

8-
#include <beman/optional/tests/test_types.hpp>
8+
#include <beman/optional/test_types.hpp>
99

1010
#include <functional>
1111
#include <ranges>

src/beman/optional/tests/optional_constexpr.t.cpp renamed to tests/beman/optional/optional_constexpr.t.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
// src/beman/optional/tests/optional_constexpr.t.cpp -*-C++-*-
1+
// tests/beman/optional/optional_constexpr.t.cpp -*-C++-*-
22
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
33

44
#include <beman/optional/optional.hpp>
5-
#include <beman/optional/tests/test_types.hpp>
6-
#include <beman/optional/tests/test_utilities.hpp>
5+
#include <beman/optional/test_types.hpp>
6+
#include <beman/optional/test_utilities.hpp>
77

88
#include <functional>
99
#include <ranges>

src/beman/optional/tests/optional_monadic.t.cpp renamed to tests/beman/optional/optional_monadic.t.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// src/beman/optional/tests/optional_monadic.t.cpp -*-C++-*-
1+
// tests/beman/optional/optional_monadic.t.cpp -*-C++-*-
22
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
33

44
#include <beman/optional/optional.hpp>

src/beman/optional/tests/optional_range_support.t.cpp renamed to tests/beman/optional/optional_range_support.t.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// src/beman/optional/tests/optional_range_support.t.cpp -*-C++-*-
1+
// tests/beman/optional/optional_range_support.t.cpp -*-C++-*-
22
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
33

44
/**
@@ -13,7 +13,7 @@
1313
#include <gtest/gtest.h>
1414

1515
#include <beman/optional/detail/iterator.hpp>
16-
#include <beman/optional/tests/test_types.hpp>
16+
#include <beman/optional/test_types.hpp>
1717

1818
#include <algorithm>
1919
#include <concepts>

src/beman/optional/tests/optional_ref.t.cpp renamed to tests/beman/optional/optional_ref.t.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
// src/beman/optional/tests/optional_ref.t.cpp -*-C++-*-
1+
// tests/beman/optional/optional_ref.t.cpp -*-C++-*-
22
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
33

44
#include <beman/optional/optional.hpp>
5-
#include <beman/optional/tests/test_types.hpp>
5+
#include <beman/optional/test_types.hpp>
66

77
#include <gtest/gtest.h>
88

src/beman/optional/tests/optional_ref_monadic.t.cpp renamed to tests/beman/optional/optional_ref_monadic.t.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// src/beman/optional/tests/optional_ref_monadic.t.cpp -*-C++-*-
1+
// tests/beman/optional/optional_ref_monadic.t.cpp -*-C++-*-
22
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
33

44
#include <beman/optional/optional.hpp>

src/beman/optional/tests/test_constructor_fail.cpp renamed to tests/beman/optional/test_constructor_fail.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// src/beman/optional/tests/test_constructor_fail.t.cpp -*-C++-*-
1+
// tests/beman/optional/test_constructor_fail.t.cpp -*-C++-*-
22
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
33

44
#include <beman/optional/optional.hpp>

0 commit comments

Comments
 (0)