![]() |
This is Unofficial EPICS BASE Doxygen Site
|
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "epicsThread.h"
#include "epicsMutex.h"
#include "epicsUnitTest.h"
#include "epicsExit.h"
#include "epicsTime.h"
#include "ellLib.h"
#include "errlog.h"
#include "cantProceed.h"
#include "epicsStackTrace.h"
Go to the source code of this file.
Classes | |
struct | testFailure |
Functions | |
void | testPlan (int plan) |
Declare the test plan, required. More... | |
int | testOkV (int pass, const char *fmt, va_list pvar) |
Test result with var-args description. More... | |
int | testOk (int pass, const char *fmt,...) |
void | testPass (const char *fmt,...) |
void | testFail (const char *fmt,...) |
void | testSkip (int skip, const char *why) |
Place-holders for tests that can't be run. More... | |
void | testTodoBegin (const char *why) |
Mark the start of a group of tests that are expected to fail. More... | |
void | testTodoEnd (void) |
Mark the end of a failing test group. More... | |
int | testDiag (const char *fmt,...) |
void | testAbort (const char *fmt,...) |
int | testDone (void) |
Mark the end of testing. More... | |
int | testImpreciseTiming (void) |
Return non-zero in shared/oversubscribed testing envrionments. More... | |
void | testHarnessExit (void *dummy) |
void | testHarness (void) |
Initialize test harness. More... | |
void | runTestFunc (const char *name, TESTFUNC func) |
Variables | |
epicsTimeStamp | started |
ELLLIST | faults |
const char * | testing = NULL |
void runTestFunc | ( | const char * | name, |
TESTFUNC | func | ||
) |
Definition at line 310 of file epicsUnitTest.c.
void testAbort | ( | const char * | fmt, |
... | |||
) |
Definition at line 194 of file epicsUnitTest.c.
int testDiag | ( | const char * | fmt, |
... | |||
) |
Definition at line 181 of file epicsUnitTest.c.
int testDone | ( | void | ) |
Mark the end of testing.
Definition at line 209 of file epicsUnitTest.c.
void testFail | ( | const char * | fmt, |
... | |||
) |
Definition at line 152 of file epicsUnitTest.c.
void testHarness | ( | void | ) |
Initialize test harness.
Definition at line 300 of file epicsUnitTest.c.
void testHarnessExit | ( | void * | dummy | ) |
Definition at line 265 of file epicsUnitTest.c.
int testImpreciseTiming | ( | void | ) |
Return non-zero in shared/oversubscribed testing envrionments.
May be used to testSkip(), or select longer timeouts, for some cases when the test process may be preempted for arbitrarily long times. This is common in shared CI environments.
The environment variable $EPICS_TEST_IMPRECISE_TIMING=YES should be set in by such testing environments.
Definition at line 253 of file epicsUnitTest.c.
int testOk | ( | int | pass, |
const char * | fmt, | ||
... | |||
) |
Definition at line 137 of file epicsUnitTest.c.
int testOkV | ( | int | pass, |
const char * | fmt, | ||
va_list | pvar | ||
) |
Test result with var-args description.
pass | True/False value indicating result. |
fmt | A printf-style format string describing the test. |
pvar | A var-args pointer to any parameters for the format string. |
pass
. Definition at line 112 of file epicsUnitTest.c.
void testPass | ( | const char * | fmt, |
... | |||
) |
Definition at line 145 of file epicsUnitTest.c.
void testPlan | ( | int | tests | ) |
Declare the test plan, required.
tests | Number of tests to be run. May be zero if not known but the test harness then can't tell if the program dies prematurely. |
Definition at line 102 of file epicsUnitTest.c.
void testSkip | ( | int | skip, |
const char * | why | ||
) |
Place-holders for tests that can't be run.
skip | How many tests are being skipped. |
why | Reason for skipping these tests. |
Definition at line 159 of file epicsUnitTest.c.
void testTodoBegin | ( | const char * | why | ) |
Mark the start of a group of tests that are expected to fail.
why | Reason for expected failures. |
Definition at line 171 of file epicsUnitTest.c.
void testTodoEnd | ( | void | ) |
Mark the end of a failing test group.
Definition at line 177 of file epicsUnitTest.c.
ELLLIST faults |
Definition at line 57 of file epicsUnitTest.c.
epicsTimeStamp started |
Definition at line 52 of file epicsUnitTest.c.
const char* testing = NULL |
Definition at line 58 of file epicsUnitTest.c.