[MQTT] Simplifies MQTT CMakeLists file

- Uses mocks from tools instead of creating them.
- Move host based definition to test code.
This commit is contained in:
Euripedes Rocha
2022-09-05 15:46:10 +02:00
committed by Rocha Euripedes
parent dd441ef713
commit 736424c366
23 changed files with 190 additions and 165 deletions

View File

@@ -0,0 +1,8 @@
# NOTE: This kind of mocking currently works on Linux targets only.
# On Espressif chips, too many dependencies are missing at the moment.
message(STATUS "building HTTP PARSER MOCKS")
idf_component_get_property(original_http_parser_dir http_parser COMPONENT_OVERRIDEN_DIR)
idf_component_mock(INCLUDE_DIRS "${original_http_parser_dir}"
MOCK_HEADER_FILES ${original_http_parser_dir}/http_parser.h)

View File

@@ -0,0 +1,9 @@
:cmock:
:plugins:
- expect
- expect_any_args
- return_thru_ptr
- array
- ignore
- ignore_arg
- callback