PKUOS - Pintos
Pintos source browser for PKU Operating System course
|
Go to the source code of this file.
Data Structures | |
struct | test |
Functions | |
void | run_test (const char *name) |
Runs the test named NAME. More... | |
void | msg (const char *format,...) |
Prints FORMAT as if with printf(), prefixing the output by the name of the test and following it with a new-line character. More... | |
void | fail (const char *format,...) |
Prints failure message FORMAT as if with printf(), prefixing the output by the name of the test and FAIL: and following it with a new-line character, and then panics the kernel. More... | |
void | pass (void) |
Prints a message indicating the current test passed. More... | |
Variables | |
static const struct test | tests [] |
static const char * | test_name |
void fail | ( | const char * | format, |
... | |||
) |
Prints failure message FORMAT as if with printf(), prefixing the output by the name of the test and FAIL: and following it with a new-line character, and then panics the kernel.
Definition at line 83 of file tests.c.
References PANIC, printf(), putchar(), test_name, va_end, va_start, and vprintf().
void msg | ( | const char * | format, |
... | |||
) |
Prints FORMAT as if with printf(), prefixing the output by the name of the test and following it with a new-line character.
Definition at line 67 of file tests.c.
References printf(), putchar(), test_name, va_end, va_start, and vprintf().
Referenced by run_test().
void pass | ( | void | ) |
void run_test | ( | const char * | name | ) |
Runs the test named NAME.
Definition at line 47 of file tests.c.
References test::function, msg(), name, test::name, PANIC, strcmp(), test_name, and tests.
Referenced by run_task().
|
static |
|
static |
Definition at line 12 of file tests.c.
Referenced by run_test().