mirror of
https://github.com/BlackMATov/kari.hpp.git
synced 2025-12-13 13:06:17 +07:00
fix catch2 tag
This commit is contained in:
16
README.md
16
README.md
@@ -1,4 +1,4 @@
|
||||
# kari.hpp [](https://twitter.com/intent/tweet?text=Experimental%20library%20for%20currying%20in%20C%2B%2B17&url=https://github.com/BlackMATov/kari.hpp&via=BMEngine&hashtags=cpp,currying,cpp17,functionalprogramming)
|
||||
# kari.hpp
|
||||
|
||||
> Experimental library for currying in C++17
|
||||
|
||||
@@ -9,9 +9,9 @@
|
||||
[![license][badge.license]][license]
|
||||
[![paypal][badge.paypal]][paypal]
|
||||
|
||||
[badge.travis]: https://img.shields.io/travis/BlackMATov/kari.hpp/master.svg?logo=travis
|
||||
[badge.appveyor]: https://img.shields.io/appveyor/ci/BlackMATov/kari-hpp/master.svg?logo=appveyor
|
||||
[badge.codecov]: https://img.shields.io/codecov/c/github/BlackMATov/kari.hpp/master.svg?logo=codecov
|
||||
[badge.travis]: https://img.shields.io/travis/BlackMATov/kari.hpp/main.svg?logo=travis
|
||||
[badge.appveyor]: https://img.shields.io/appveyor/ci/BlackMATov/kari-hpp/main.svg?logo=appveyor
|
||||
[badge.codecov]: https://img.shields.io/codecov/c/github/BlackMATov/kari.hpp/main.svg?logo=codecov
|
||||
[badge.language]: https://img.shields.io/badge/language-C%2B%2B17-yellow.svg
|
||||
[badge.license]: https://img.shields.io/badge/license-MIT-blue.svg
|
||||
[badge.paypal]: https://img.shields.io/badge/donate-PayPal-orange.svg?logo=paypal&colorA=00457C
|
||||
@@ -20,11 +20,17 @@
|
||||
[appveyor]: https://ci.appveyor.com/project/BlackMATov/kari-hpp
|
||||
[codecov]: https://codecov.io/gh/BlackMATov/kari.hpp
|
||||
[language]: https://en.wikipedia.org/wiki/C%2B%2B17
|
||||
[license]: https://github.com/BlackMATov/kari.hpp/blob/master/LICENSE.md
|
||||
[license]: https://en.wikipedia.org/wiki/MIT_License
|
||||
[paypal]: https://www.paypal.me/matov
|
||||
|
||||
[kari]: https://github.com/BlackMATov/kari.hpp
|
||||
|
||||
## Requirements
|
||||
|
||||
- [gcc](https://www.gnu.org/software/gcc/) **>= 7**
|
||||
- [clang](https://clang.llvm.org/) **>= 5.0**
|
||||
- [msvc](https://visualstudio.microsoft.com/) **>= 2017**
|
||||
|
||||
## Installation
|
||||
|
||||
[kari.hpp][kari] is a header-only library. All you need to do is copy the headers files from `headers` directory into your project and include them:
|
||||
|
||||
@@ -3,18 +3,9 @@ cmake_minimum_required(VERSION 3.11 FATAL_ERROR)
|
||||
|
||||
project(kari.hpp.untests)
|
||||
|
||||
set(CATCH_BUILD_TESTING OFF CACHE BOOL "" FORCE)
|
||||
|
||||
include(FetchContent)
|
||||
FetchContent_Declare(
|
||||
catch2
|
||||
GIT_REPOSITORY https://github.com/catchorg/catch2)
|
||||
|
||||
FetchContent_GetProperties(catch2)
|
||||
if(NOT catch2_POPULATED)
|
||||
FetchContent_Populate(catch2)
|
||||
add_subdirectory(${catch2_SOURCE_DIR} ${catch2_BINARY_DIR})
|
||||
endif()
|
||||
#
|
||||
# coverage
|
||||
#
|
||||
|
||||
option(BUILD_WITH_COVERAGE "Build with coverage" OFF)
|
||||
if(BUILD_WITH_COVERAGE AND (CMAKE_CXX_COMPILER_ID MATCHES "GNU|Clang"))
|
||||
@@ -24,11 +15,14 @@ if(BUILD_WITH_COVERAGE AND (CMAKE_CXX_COMPILER_ID MATCHES "GNU|Clang"))
|
||||
set(CMAKE_LINKER_FLAGS_DEBUG "${CMAKE_LINKER_FLAGS_DEBUG} ${COVERAGE_FLAGS}")
|
||||
endif()
|
||||
|
||||
#
|
||||
# executable
|
||||
#
|
||||
|
||||
file(GLOB UNTESTS_SOURCES "*.cpp" "*.hpp")
|
||||
add_executable(${PROJECT_NAME} ${UNTESTS_SOURCES})
|
||||
target_link_libraries(${PROJECT_NAME}
|
||||
Catch2
|
||||
kari.hpp)
|
||||
target_link_libraries(${PROJECT_NAME} kari.hpp)
|
||||
|
||||
target_compile_options(${PROJECT_NAME}
|
||||
PRIVATE
|
||||
$<$<CXX_COMPILER_ID:MSVC>:
|
||||
@@ -36,4 +30,22 @@ target_compile_options(${PROJECT_NAME}
|
||||
PRIVATE
|
||||
$<$<OR:$<CXX_COMPILER_ID:GNU>,$<CXX_COMPILER_ID:Clang>,$<CXX_COMPILER_ID:AppleClang>>:
|
||||
-Wall -Wextra -Wpedantic>)
|
||||
|
||||
add_test(${PROJECT_NAME} ${PROJECT_NAME})
|
||||
|
||||
#
|
||||
# catchorg/catch2
|
||||
#
|
||||
|
||||
include(FetchContent)
|
||||
FetchContent_Declare(
|
||||
catchorg_catch2
|
||||
GIT_REPOSITORY https://github.com/catchorg/catch2
|
||||
GIT_TAG v2.13.2)
|
||||
|
||||
FetchContent_GetProperties(catchorg_catch2)
|
||||
if(NOT catchorg_catch2_POPULATED)
|
||||
FetchContent_Populate(catchorg_catch2)
|
||||
target_include_directories(${PROJECT_NAME}
|
||||
PRIVATE ${catchorg_catch2_SOURCE_DIR}/single_include)
|
||||
endif()
|
||||
|
||||
Reference in New Issue
Block a user