aboutsummaryrefslogtreecommitdiffstats
path: root/nihil.error/CMakeLists.txt
blob: 37fb3aba361ec0f0353695dabb19b0634030bcdd (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
# This source code is released into the public domain.

add_library(nihil.error STATIC)
target_link_libraries(nihil.error PRIVATE nihil.match)
target_sources(nihil.error
	PUBLIC FILE_SET modules TYPE CXX_MODULES FILES
	error.ccm

	PRIVATE
	error.cc
)

if(NIHIL_TESTS)
	enable_testing()

	add_executable(nihil.error.test
		test.cc)

	target_link_libraries(nihil.error.test PRIVATE
		nihil.error
		Catch2::Catch2WithMain
	)

	include(CTest)
	include(Catch)
	catch_discover_tests(nihil.error.test)
endif()