mirror of
https://github.com/RGBCube/serenity
synced 2025-07-28 10:47:34 +00:00
Tests: Reorganize LibCompress unit tests
Move LibCompress unit tests to LibCompress/Tests directory and register them with CMake's add_test. This allows us to run these tests with ninja test instead of running a separate executable. Also split the existing tests in 3 test files that better follow the source code structure (inspired by AK tests).
This commit is contained in:
parent
78733417a4
commit
8124719c3d
8 changed files with 191 additions and 117 deletions
8
Userland/Libraries/LibCompress/Tests/CMakeLists.txt
Normal file
8
Userland/Libraries/LibCompress/Tests/CMakeLists.txt
Normal file
|
@ -0,0 +1,8 @@
|
|||
file(GLOB TEST_SOURCES CONFIGURE_DEPENDS "*.cpp")
|
||||
|
||||
foreach(source ${TEST_SOURCES})
|
||||
get_filename_component(name ${source} NAME_WE)
|
||||
add_executable(${name} ${source})
|
||||
target_link_libraries(${name} LibCore LibCompress)
|
||||
install(TARGETS ${name} RUNTIME DESTINATION usr/Tests/LibCompress)
|
||||
endforeach()
|
Loading…
Add table
Add a link
Reference in a new issue