From fee029829d59971746ff94b0a609d0879de629f8 Mon Sep 17 00:00:00 2001 From: Paul Date: Sun, 28 Jul 2024 09:18:59 -0400 Subject: [PATCH] Github Actions upgrade (#123) add code qual check move catch2 out of source dir --- .github/workflows/code-checks.yml | 17 +++++++++++++++++ CMakeLists.txt | 3 ++- {tests => libs/catch2}/catch2.hpp | 0 3 files changed, 19 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/code-checks.yml rename {tests => libs/catch2}/catch2.hpp (100%) diff --git a/.github/workflows/code-checks.yml b/.github/workflows/code-checks.yml new file mode 100644 index 0000000..ced2850 --- /dev/null +++ b/.github/workflows/code-checks.yml @@ -0,0 +1,17 @@ +name: Format Check +on: [pull_request] +jobs: + formatting-check: + name: Clang Format Check + runs-on: ubuntu-latest + strategy: + matrix: + path: [ 'tests', 'include' ] + steps: + - name: Checkout code + uses: actions/checkout@v3 + + - name: Run clang-format style check + uses: surge-synthesizer/sst-githubactions/clang-format-check@main + with: + path: ${{ matrix.path }} diff --git a/CMakeLists.txt b/CMakeLists.txt index d7a5686..372f7ec 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -73,6 +73,7 @@ if (${SST_EFFECTS_BUILD_TESTS}) target_link_libraries(${PROJECT_NAME}-test PUBLIC simde sst-basic-blocks sst-filters sst-waveshapers fmt ${PROJECT_NAME}) target_compile_definitions(${PROJECT_NAME}-test PUBLIC _USE_MATH_DEFINES=1) target_compile_definitions(${PROJECT_NAME}-test PRIVATE CATCH_CONFIG_DISABLE_EXCEPTIONS=1) + target_include_directories(${PROJECT_NAME}-test PRIVATE libs/catch2) endif () @@ -82,4 +83,4 @@ if (TARGET eurorack) target_compile_definitions(${PROJECT_NAME} INTERFACE SST_EFFECTS_EURORACK=1) else() message(STATUS "sst-effects built without eurorack library; Nimbus effect is no-op") -endif() \ No newline at end of file +endif() diff --git a/tests/catch2.hpp b/libs/catch2/catch2.hpp similarity index 100% rename from tests/catch2.hpp rename to libs/catch2/catch2.hpp