/* * SPDX-FileCopyrightText: 2024 Espressif Systems (Shanghai) CO LTD * * SPDX-License-Identifier: Apache-2.0 *//* ... */#ifndefUNITY_CONFIG_H#defineUNITY_CONFIG_H// This file gets included from unity.h via unity_internals.h// It is inside #ifdef __cplusplus / extern "C" block, so we can// only use C features here#include<esp_err.h>#include<stddef.h>#include<math.h>#include"sdkconfig.h"#ifdefCONFIG_UNITY_ENABLE_FLOAT#defineUNITY_INCLUDE_FLOAT#else#defineUNITY_EXCLUDE_FLOAT#endif//CONFIG_UNITY_ENABLE_FLOAT#ifdefCONFIG_UNITY_ENABLE_DOUBLE#defineUNITY_INCLUDE_DOUBLE#else#defineUNITY_EXCLUDE_DOUBLE#endif//CONFIG_UNITY_ENABLE_DOUBLE#ifdefCONFIG_UNITY_ENABLE_64BIT#defineUNITY_SUPPORT_64#endif#ifdefCONFIG_UNITY_ENABLE_COLOR#defineUNITY_OUTPUT_COLOR#endif#ifndef__cplusplus#defineUNITY_IS_NANisnan#defineUNITY_IS_INFisinf/* ... */#else#defineUNITY_IS_NANstd::isnan#defineUNITY_IS_INFstd::isinf/* ... */#endif// Note, using __noreturn__ rather than noreturn// https://github.com/espressif/esp-idf/issues/11339#defineUNITY_NORETURN__attribute__((__noreturn__))#defineUNITY_EXCLUDE_TIME_Hvoidunity_flush(void);voidunity_putc(intc);voidunity_gets(char*dst,size_tlen);voidunity_exec_time_start(void);voidunity_exec_time_stop(void);uint32_tunity_exec_time_get_ms(void);#defineUNITY_OUTPUT_CHAR(a)unity_putc(a)#defineUNITY_OUTPUT_FLUSH()unity_flush()#defineUNITY_EXEC_TIME_START()unity_exec_time_start()#defineUNITY_EXEC_TIME_STOP()unity_exec_time_stop()#defineUNITY_EXEC_TIME_MS()unity_exec_time_get_ms()5 defines#ifdefCONFIG_UNITY_ENABLE_IDF_TEST_RUNNER#include"unity_test_runner.h"/* ... */#endif//CONFIG_UNITY_ENABLE_IDF_TEST_RUNNER#ifdefCONFIG_UNITY_ENABLE_FIXTURE// Two separate "extras" options here:// 1. Disable memory allocation wrappers in Unity Fixture#defineUNITY_FIXTURE_NO_EXTRAS// 2. Add IDF-specific additions to Unity Fixture#include"unity_fixture_extras.h"/* ... */#endif// CONFIG_UNITY_ENABLE_FIXTURE// shorthand to check esp_err_t return code#defineTEST_ESP_OK(rc)TEST_ASSERT_EQUAL_HEX32(ESP_OK,rc)#defineTEST_ESP_ERR(err,rc)TEST_ASSERT_EQUAL_HEX32(err,rc)/* ... */#endif//UNITY_CONFIG_H
Details
Show: from
Types: Columns:
All items filtered out
All items filtered out
This file uses the notable symbols shown below. Click anywhere in the file to view more details.