diff --git a/tests/unit/application/test_application.cpp b/tests/unit/application/test_application.cpp index 21b7e88..0576330 100644 --- a/tests/unit/application/test_application.cpp +++ b/tests/unit/application/test_application.cpp @@ -1,4 +1,4 @@ -#include "catch2/catch_all.hpp" +#include "catch2/catch_test_macros.hpp" #include "application.h" #include #include "../modules/stubs/stub_serial.h" diff --git a/tests/unit/application/test_registers.cpp b/tests/unit/application/test_registers.cpp index 735571c..afa1f37 100644 --- a/tests/unit/application/test_registers.cpp +++ b/tests/unit/application/test_registers.cpp @@ -1,4 +1,4 @@ -#include "catch2/catch_all.hpp" +#include "catch2/catch_test_macros.hpp" #include "registers.h" #include "modules/globals.h" #include "../modules/stubs/stub_eeprom.h" diff --git a/tests/unit/hal/circular_buffer/test_circular_buffer.cpp b/tests/unit/hal/circular_buffer/test_circular_buffer.cpp index 6b23b86..0ad2803 100644 --- a/tests/unit/hal/circular_buffer/test_circular_buffer.cpp +++ b/tests/unit/hal/circular_buffer/test_circular_buffer.cpp @@ -1,4 +1,5 @@ -#include "catch2/catch_all.hpp" +#include "catch2/catch_test_macros.hpp" +#include "catch2/matchers/catch_matchers_vector.hpp" #include "circular_buffer.h" using Catch::Matchers::Equals; diff --git a/tests/unit/hal/progmem/test_progmem.cpp b/tests/unit/hal/progmem/test_progmem.cpp index 94eb7d0..b980305 100644 --- a/tests/unit/hal/progmem/test_progmem.cpp +++ b/tests/unit/hal/progmem/test_progmem.cpp @@ -1,4 +1,5 @@ -#include "catch2/catch_all.hpp" +#include "catch2/catch_test_macros.hpp" +#include "catch2/matchers/catch_matchers_vector.hpp" #include "progmem.h" using Catch::Matchers::Equals; diff --git a/tests/unit/logic/cut_filament/test_cut_filament.cpp b/tests/unit/logic/cut_filament/test_cut_filament.cpp index 18ac283..8aec809 100644 --- a/tests/unit/logic/cut_filament/test_cut_filament.cpp +++ b/tests/unit/logic/cut_filament/test_cut_filament.cpp @@ -1,4 +1,5 @@ -#include "catch2/catch_all.hpp" +#include "catch2/catch_test_macros.hpp" +#include "catch2/matchers/catch_matchers_vector.hpp" #include "../../../../src/modules/buttons.h" #include "../../../../src/modules/finda.h" diff --git a/tests/unit/logic/eject_filament/test_eject_filament.cpp b/tests/unit/logic/eject_filament/test_eject_filament.cpp index 00b15a2..f3054e3 100644 --- a/tests/unit/logic/eject_filament/test_eject_filament.cpp +++ b/tests/unit/logic/eject_filament/test_eject_filament.cpp @@ -1,4 +1,5 @@ -#include "catch2/catch_all.hpp" +#include "catch2/catch_test_macros.hpp" +#include "catch2/matchers/catch_matchers_vector.hpp" #include "../../../../src/modules/buttons.h" #include "../../../../src/modules/finda.h" diff --git a/tests/unit/logic/failing_tmc/test_failing_tmc.cpp b/tests/unit/logic/failing_tmc/test_failing_tmc.cpp index 73af815..7b998fb 100644 --- a/tests/unit/logic/failing_tmc/test_failing_tmc.cpp +++ b/tests/unit/logic/failing_tmc/test_failing_tmc.cpp @@ -2,7 +2,8 @@ // As a base for this test, unload_filament was chosen. // Moreover, I didn't want to spoil the unit tests of the state machines themself with this. -#include "catch2/catch_all.hpp" +#include "catch2/catch_test_macros.hpp" +#include "catch2/matchers/catch_matchers_vector.hpp" #include "../../../../src/modules/buttons.h" #include "../../../../src/modules/finda.h" diff --git a/tests/unit/logic/feed_to_bondtech/test_feed_to_bondtech.cpp b/tests/unit/logic/feed_to_bondtech/test_feed_to_bondtech.cpp index 96ea95a..4b04fcf 100644 --- a/tests/unit/logic/feed_to_bondtech/test_feed_to_bondtech.cpp +++ b/tests/unit/logic/feed_to_bondtech/test_feed_to_bondtech.cpp @@ -1,4 +1,5 @@ -#include "catch2/catch_all.hpp" +#include "catch2/catch_test_macros.hpp" +#include "catch2/matchers/catch_matchers_vector.hpp" #include "../../../../src/modules/buttons.h" #include "../../../../src/modules/finda.h" diff --git a/tests/unit/logic/feed_to_finda/test_feed_to_finda.cpp b/tests/unit/logic/feed_to_finda/test_feed_to_finda.cpp index 32f3eec..5ecf72b 100644 --- a/tests/unit/logic/feed_to_finda/test_feed_to_finda.cpp +++ b/tests/unit/logic/feed_to_finda/test_feed_to_finda.cpp @@ -1,4 +1,5 @@ -#include "catch2/catch_all.hpp" +#include "catch2/catch_test_macros.hpp" +#include "catch2/matchers/catch_matchers_vector.hpp" #include "../../../../src/modules/buttons.h" #include "../../../../src/modules/finda.h" diff --git a/tests/unit/logic/homing/test_homing.cpp b/tests/unit/logic/homing/test_homing.cpp index 7e7440b..88913c9 100644 --- a/tests/unit/logic/homing/test_homing.cpp +++ b/tests/unit/logic/homing/test_homing.cpp @@ -1,4 +1,5 @@ -#include "catch2/catch_all.hpp" +#include "catch2/catch_test_macros.hpp" +#include "catch2/matchers/catch_matchers_vector.hpp" #include "../../../../src/modules/buttons.h" #include "../../../../src/modules/finda.h" diff --git a/tests/unit/logic/load_filament/test_load_filament.cpp b/tests/unit/logic/load_filament/test_load_filament.cpp index 7e69e78..1c7bc43 100644 --- a/tests/unit/logic/load_filament/test_load_filament.cpp +++ b/tests/unit/logic/load_filament/test_load_filament.cpp @@ -1,4 +1,8 @@ -#include "catch2/catch_all.hpp" +#include "catch2/catch_test_macros.hpp" +#include "catch2/generators/catch_generators.hpp" +#include "catch2/matchers/catch_matchers_vector.hpp" + +#include #include "../../../../src/modules/buttons.h" #include "../../../../src/modules/finda.h" diff --git a/tests/unit/logic/stubs/main_loop_stub.cpp b/tests/unit/logic/stubs/main_loop_stub.cpp index ee49fc8..d45f9ae 100644 --- a/tests/unit/logic/stubs/main_loop_stub.cpp +++ b/tests/unit/logic/stubs/main_loop_stub.cpp @@ -1,4 +1,4 @@ -#include "catch2/catch_all.hpp" +#include "catch2/catch_test_macros.hpp" #include "main_loop_stub.h" #include "homing.h" diff --git a/tests/unit/logic/tool_change/test_tool_change.cpp b/tests/unit/logic/tool_change/test_tool_change.cpp index 8f3ee54..66212a1 100644 --- a/tests/unit/logic/tool_change/test_tool_change.cpp +++ b/tests/unit/logic/tool_change/test_tool_change.cpp @@ -1,4 +1,5 @@ -#include "catch2/catch_all.hpp" +#include "catch2/catch_test_macros.hpp" +#include "catch2/matchers/catch_matchers_vector.hpp" #include "../../../../src/modules/buttons.h" #include "../../../../src/modules/finda.h" diff --git a/tests/unit/logic/unload_filament/test_unload_filament.cpp b/tests/unit/logic/unload_filament/test_unload_filament.cpp index 3d44b65..a07773b 100644 --- a/tests/unit/logic/unload_filament/test_unload_filament.cpp +++ b/tests/unit/logic/unload_filament/test_unload_filament.cpp @@ -1,4 +1,7 @@ -#include "catch2/catch_all.hpp" +#include "catch2/catch_test_macros.hpp" +#include "catch2/matchers/catch_matchers_vector.hpp" + +#include #include "../../../../src/modules/buttons.h" #include "../../../../src/modules/finda.h" diff --git a/tests/unit/logic/unload_to_finda/test_unload_to_finda.cpp b/tests/unit/logic/unload_to_finda/test_unload_to_finda.cpp index 998ba82..31304d9 100644 --- a/tests/unit/logic/unload_to_finda/test_unload_to_finda.cpp +++ b/tests/unit/logic/unload_to_finda/test_unload_to_finda.cpp @@ -1,4 +1,6 @@ -#include "catch2/catch_all.hpp" +#include "catch2/catch_test_macros.hpp" +#include "catch2/generators/catch_generators_range.hpp" +#include "catch2/matchers/catch_matchers_vector.hpp" #include diff --git a/tests/unit/modules/buttons/test_buttons.cpp b/tests/unit/modules/buttons/test_buttons.cpp index 90ceebf..1885755 100644 --- a/tests/unit/modules/buttons/test_buttons.cpp +++ b/tests/unit/modules/buttons/test_buttons.cpp @@ -1,4 +1,4 @@ -#include "catch2/catch_all.hpp" +#include "catch2/catch_test_macros.hpp" #include "../stubs/stub_adc.h" #include "../stubs/stub_timebase.h" #include "buttons.h" diff --git a/tests/unit/modules/leds/test_leds.cpp b/tests/unit/modules/leds/test_leds.cpp index 15a19de..5aee35c 100644 --- a/tests/unit/modules/leds/test_leds.cpp +++ b/tests/unit/modules/leds/test_leds.cpp @@ -1,4 +1,6 @@ -#include "catch2/catch_all.hpp" +#include "catch2/catch_test_macros.hpp" +#include "catch2/generators/catch_generators.hpp" +#include "catch2/matchers/catch_matchers_vector.hpp" #include "leds.h" #include "shr16.h" #include "../stubs/stub_timebase.h" diff --git a/tests/unit/modules/motion/test_motion.cpp b/tests/unit/modules/motion/test_motion.cpp index 6efc765..7bbae19 100644 --- a/tests/unit/modules/motion/test_motion.cpp +++ b/tests/unit/modules/motion/test_motion.cpp @@ -1,4 +1,4 @@ -#include "catch2/catch_all.hpp" +#include "catch2/catch_test_macros.hpp" #include "motion.h" using namespace modules::motion; diff --git a/tests/unit/modules/protocol/test_protocol.cpp b/tests/unit/modules/protocol/test_protocol.cpp index 70b631a..53e8e4d 100644 --- a/tests/unit/modules/protocol/test_protocol.cpp +++ b/tests/unit/modules/protocol/test_protocol.cpp @@ -1,8 +1,10 @@ -#include "catch2/catch_all.hpp" +#include "catch2/catch_test_macros.hpp" +#include "catch2/generators/catch_generators.hpp" #include "../logic/error_codes.h" #include "../logic/progress_codes.h" #include "protocol.h" #include +#include // some safe margin for the buffer using TXBuff = std::array; diff --git a/tests/unit/modules/pulse_gen/test_pulse_gen.cpp b/tests/unit/modules/pulse_gen/test_pulse_gen.cpp index d447031..581b116 100644 --- a/tests/unit/modules/pulse_gen/test_pulse_gen.cpp +++ b/tests/unit/modules/pulse_gen/test_pulse_gen.cpp @@ -1,4 +1,5 @@ -#include "catch2/catch_all.hpp" +#include "catch2/catch_test_macros.hpp" +#include "catch2/matchers/catch_matchers_vector.hpp" #include "pulse_gen.h" #include "../pins.h" #include diff --git a/tests/unit/modules/speed_table/test_speed_table.cpp b/tests/unit/modules/speed_table/test_speed_table.cpp index 8011959..ffc172a 100644 --- a/tests/unit/modules/speed_table/test_speed_table.cpp +++ b/tests/unit/modules/speed_table/test_speed_table.cpp @@ -1,4 +1,5 @@ -#include "catch2/catch_all.hpp" +#include "catch2/catch_test_macros.hpp" +#include "catch2/matchers/catch_matchers_vector.hpp" #include "speed_table.h" #include diff --git a/tests/unit/modules/stubs/stub_eeprom.cpp b/tests/unit/modules/stubs/stub_eeprom.cpp index 3a2a933..141d177 100644 --- a/tests/unit/modules/stubs/stub_eeprom.cpp +++ b/tests/unit/modules/stubs/stub_eeprom.cpp @@ -1,4 +1,4 @@ -#include "catch2/catch_all.hpp" +#include "catch2/catch_test_macros.hpp" #include "../../../../src/hal/eeprom.h" #include "stub_eeprom.h" diff --git a/tests/unit/modules/timebase/test_timebase.cpp b/tests/unit/modules/timebase/test_timebase.cpp index d295568..7e23055 100644 --- a/tests/unit/modules/timebase/test_timebase.cpp +++ b/tests/unit/modules/timebase/test_timebase.cpp @@ -1,4 +1,5 @@ -#include "catch2/catch_all.hpp" +#include "catch2/catch_test_macros.hpp" +#include "catch2/matchers/catch_matchers_vector.hpp" #include "timebase.h" #include "../stubs/stub_timebase.h" diff --git a/tests/unit/modules/user_input/test_user_input.cpp b/tests/unit/modules/user_input/test_user_input.cpp index fe09a22..2bad346 100644 --- a/tests/unit/modules/user_input/test_user_input.cpp +++ b/tests/unit/modules/user_input/test_user_input.cpp @@ -1,4 +1,5 @@ -#include "catch2/catch_all.hpp" +#include "catch2/catch_test_macros.hpp" +#include "catch2/generators/catch_generators.hpp" #include "../stubs/stub_adc.h" #include "../stubs/stub_timebase.h" #include "buttons.h" diff --git a/tests/unit/system_test.cpp b/tests/unit/system_test.cpp index 4ccecfa..d7db0c6 100644 --- a/tests/unit/system_test.cpp +++ b/tests/unit/system_test.cpp @@ -1,4 +1,4 @@ -#include "catch2/catch_all.hpp" +#include "catch2/catch_test_macros.hpp" TEST_CASE("type tests", "[system]") { REQUIRE(sizeof(uint64_t) == 8); diff --git a/tests/unit/test_main.cpp b/tests/unit/test_main.cpp index ae21725..08a5a7d 100644 --- a/tests/unit/test_main.cpp +++ b/tests/unit/test_main.cpp @@ -1,2 +1 @@ //#define CATCH_CONFIG_ENABLE_BENCHMARKING -#include "catch2/catch_all.hpp"