diff --git a/.github/workflows/build-arm-mac.yml b/.github/workflows/build-arm-mac.yml index 0965e8571..1e98956f2 100644 --- a/.github/workflows/build-arm-mac.yml +++ b/.github/workflows/build-arm-mac.yml @@ -19,7 +19,7 @@ jobs: fail-fast: false # show all errors for each platform (vs. cancel jobs on error) matrix: tests: ["chowdsp_buffers_test chowdsp_dsp_data_structures_test chowdsp_dsp_juce_test chowdsp_dsp_utils_test chowdsp_sources_test chowdsp_math_test chowdsp_simd_test chowdsp_filters_test chowdsp_waveshapers_test chowdsp_modal_dsp_test chowdsp_compressor_test"] - os: [macos-latest] + os: [macos-14] steps: - name: Get latest CMake @@ -49,3 +49,13 @@ jobs: env: TEST_TARGETS: ${{ matrix.tests }} run: cmake --build . --config Release --parallel 4 --target $TEST_TARGETS | xcpretty + + - name: "Run Tests: ${{ matrix.tests }}" + if: (! matrix.live_gui) + working-directory: ${{env.WORK_DIR}} + shell: bash + env: + TEST_TARGETS: ${{ matrix.tests }} + run: | + ctest --test-dir build -C Release -R ${TEST_TARGETS// /|} --show-only + ctest --test-dir build -C Release -R ${TEST_TARGETS// /|} -j 4 --output-on-failure diff --git a/modules/common/chowdsp_logging/Loggers/chowdsp_Logger.cpp b/modules/common/chowdsp_logging/Loggers/chowdsp_Logger.cpp index 3b2157fe8..03a151b01 100644 --- a/modules/common/chowdsp_logging/Loggers/chowdsp_Logger.cpp +++ b/modules/common/chowdsp_logging/Loggers/chowdsp_Logger.cpp @@ -16,7 +16,7 @@ static juce::File getSystemLogFileFolder() #endif } -Logger::Logger (LogFileParams loggerParams) : params (loggerParams) +Logger::Logger (const LogFileParams& loggerParams) : params (loggerParams) { using namespace LogFileHelpers; using namespace CrashLogHelpers; @@ -45,7 +45,14 @@ Logger::Logger (LogFileParams loggerParams) : params (loggerParams) Logger::~Logger() { - logger.internal_logger.flush(); + try + { + logger.internal_logger.flush(); + } + catch (const spdlog::spdlog_ex &ex) + { + jassertfalse; + } LogFileHelpers::shutdownLogger(); } } // namespace chowdsp diff --git a/modules/common/chowdsp_logging/Loggers/chowdsp_Logger.h b/modules/common/chowdsp_logging/Loggers/chowdsp_Logger.h index 6d72c693f..5e61f70c2 100644 --- a/modules/common/chowdsp_logging/Loggers/chowdsp_Logger.h +++ b/modules/common/chowdsp_logging/Loggers/chowdsp_Logger.h @@ -6,7 +6,7 @@ class Logger { public: Logger (const juce::String& logFileSubDir, const juce::String& logFileNameRoot); - explicit Logger (LogFileParams loggerParams); + explicit Logger (const LogFileParams& loggerParams); ~Logger(); [[nodiscard]] const juce::File& getLogFile() const { return log_file; }