renamed check_values() to test_context_compare() and reimplemented

This commit is contained in:
jlamothe
2023-11-20 01:16:44 +00:00
parent f808eb4cb0
commit eaa8ae06a7
2 changed files with 58 additions and 50 deletions

32
9unit.h
View File

@@ -115,6 +115,22 @@ extern void test_context_with(
void * // the value being passed in
);
// Passes two values into a test context
void test_context_compare(
TestState *, // the current state
const char *, // the context label
// test function
void (*)(
TestState *, // the current state
void *, // the first value
void * // the second value
),
void *, // the first value
void * // the second value
);
// Runs a single test with a context label
extern void single_test_context(
TestState *, // the current state
@@ -136,20 +152,4 @@ extern void single_test_context_with(
void * // the value being passed
);
// Runs a test to check a value
extern void check_value(
TestState *, // the current test state
const char *, // a description of the context
// the test function
void (*)(
TestState *,
void *, // the check value
void * // the reference value
),
void *, // the value being checked
void * // the reference value
);
//jl