|
Ghidra Decompiler Analysis Engine
|
Simple test framework. More...
#include <vector>#include <set>#include <string>#include <iostream>
Go to the source code of this file.
Classes | |
| struct | UnitTest |
| Simple unit test class. More... | |
Macros | |
| #define | TEST(testname) |
| Main unit test macro. More... | |
| #define | ASSERT(test) |
| Assert that a boolean is true for a unit test. More... | |
| #define | ASSERT_EQUALS(a, b) |
| Assert that two values are equal for a unit test. More... | |
| #define | ASSERT_NOT_EQUALS(a, b) |
| Assert that two values are not equal for a unit test. More... | |
Typedefs | |
| typedef void(* | testfunc_t) () |
| A unit-test function. | |
Simple test framework.
Include this file and any additional headers. Use TEST(testname) as prototype in test function definitions. E.g. test.cc: #include "float.hh" #include "test.hh"
TEST(zero_is_less_than_one) { ASSERT(0.0 < 1.0); }
| #define ASSERT | ( | test | ) |
Assert that a boolean is true for a unit test.
| #define ASSERT_EQUALS | ( | a, | |
| b | |||
| ) |
Assert that two values are equal for a unit test.
| #define ASSERT_NOT_EQUALS | ( | a, | |
| b | |||
| ) |
Assert that two values are not equal for a unit test.
| #define TEST | ( | testname | ) |
Main unit test macro.
1.8.17