mirror of
https://github.com/espressif/esp-idf.git
synced 2024-10-05 20:47:46 -04:00
ci(log): upgrade to Catch2 as a component
This commit is contained in:
parent
88e77ba1ed
commit
33896fe67e
@ -1,5 +1,8 @@
|
||||
idf_component_register(SRCS "log_test.cpp"
|
||||
INCLUDE_DIRS
|
||||
"."
|
||||
$ENV{IDF_PATH}/tools/catch
|
||||
REQUIRES log)
|
||||
INCLUDE_DIRS "."
|
||||
REQUIRES log
|
||||
WHOLE_ARCHIVE)
|
||||
|
||||
# Currently 'main' for IDF_TARGET=linux is defined in freertos component.
|
||||
# Since we are using a freertos mock here, need to let Catch2 provide 'main'.
|
||||
target_link_libraries(${COMPONENT_LIB} PRIVATE Catch2WithMain)
|
||||
|
2
components/log/host_test/log_test/main/idf_component.yml
Normal file
2
components/log/host_test/log_test/main/idf_component.yml
Normal file
@ -0,0 +1,2 @@
|
||||
dependencies:
|
||||
espressif/catch2: "^3.4.0"
|
@ -6,13 +6,12 @@
|
||||
software is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
|
||||
CONDITIONS OF ANY KIND, either express or implied.
|
||||
*/
|
||||
#define CATCH_CONFIG_MAIN
|
||||
#include <cstdio>
|
||||
#include <regex>
|
||||
#include <iostream>
|
||||
#include "esp_log.h"
|
||||
|
||||
#include "catch.hpp"
|
||||
#include <catch2/catch_test_macros.hpp>
|
||||
|
||||
using namespace std;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user