microReticulum/test/test_example/test_main.cpp

51 lines
812 B
C++
Raw Permalink Normal View History

2025-08-25 14:42:15 -06:00
#include <unity.h>
void testExample() {
bool success = true;
TEST_ASSERT_EQUAL(true, success);
}
2025-08-25 14:42:15 -06:00
void setUp(void) {
// set stuff up here before each test
}
void tearDown(void) {
// clean stuff up here after each test
}
int runUnityTests(void) {
UNITY_BEGIN();
// Suite-level setup
// Run tests
2025-08-25 14:42:15 -06:00
RUN_TEST(testExample);
// Suite-level teardown
2025-08-25 14:42:15 -06:00
return UNITY_END();
}
// For native dev-platform or for some embedded frameworks
int main(void) {
return runUnityTests();
}
#ifdef ARDUINO
// For Arduino framework
void setup() {
// Wait ~2 seconds before the Unity test runner
// establishes connection with a board Serial interface
delay(2000);
runUnityTests();
}
void loop() {}
#endif
// For ESP-IDF framework
void app_main() {
runUnityTests();
}