Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 16 additions & 1 deletion tests/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,23 @@ add_executable(${PROJECT_NAME}
variant_test.cpp
)

if (${CMAKE_CXX_COMPILER_ID} MATCHES "GNU|Clang")
set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_STANDARD_REQUIRED ON)

if (CMAKE_CXX_COMPILER_ID MATCHES "GNU")
target_compile_options(${PROJECT_NAME}
PRIVATE
-std=gnu++17
)
else()
target_compile_options(${PROJECT_NAME}
PRIVATE
-std=c++17
)
endif()

if (CMAKE_CXX_COMPILER_ID MATCHES "GNU|Clang")
add_compile_options(${PROJECT_NAME}
PRIVATE
-Wall -Wextra -Werror -ansi -pedantic
)
Expand Down
2 changes: 1 addition & 1 deletion tests/function_test.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#include <catch2/catch.hpp>
#include <catch2/catch_all.hpp>

#include <kitten/instances/function.h>
#include <string>
Expand Down
4 changes: 3 additions & 1 deletion tests/main.cpp
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
#define CATCH_CONFIG_MAIN

#include <catch2/catch.hpp>
#include <catch2/catch_all.hpp>

int main() { return 0; }
2 changes: 1 addition & 1 deletion tests/optional_test.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#include <catch2/catch.hpp>
#include <catch2/catch_all.hpp>

#include <kitten/instances/optional.h>
#include <string>
Expand Down
2 changes: 1 addition & 1 deletion tests/sequence_container_test.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#include <catch2/catch.hpp>
#include <catch2/catch_all.hpp>

#include "utils.h"
#include <functional>
Expand Down
2 changes: 1 addition & 1 deletion tests/variant_test.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#include <catch2/catch.hpp>
#include <catch2/catch_all.hpp>

#include <optional>
#include <string>
Expand Down