Crinit -- Configurable Rootfs Init
|
Header declaring the unit tests for crinitEnvVarInnerLex(). More...
Go to the source code of this file.
Functions | |
void | crinitEnvVarInnerLexTestSuccess (void **state) |
void | crinitEnvVarInnerLexTestNullInput (void **state) |
void | crinitEnvVarInnerLexTestLexerError (void **state) |
Header declaring the unit tests for crinitEnvVarInnerLex().
void crinitEnvVarInnerLexTestLexerError | ( | void ** | state | ) |
Tests cases leading to a lexer error (CRINIT_TK_ERR).
For crinitEnvVarInnerLex() that can only happen if the input string starts with a character not allowed in an environment key AND is not an opening double quote.
void crinitEnvVarInnerLexTestNullInput | ( | void ** | state | ) |
Tests detection of NULL pointer inputs.
crinitEnvVarInnerLex() shall fail if any pointer input parameter is NULL and/or the string in *s is NULL.
void crinitEnvVarInnerLexTestSuccess | ( | void ** | state | ) |
Tests successful lex-ing of valid inputs.
All possible return values of crinitEnvVarInnerLex() save for CRINIT_TK_ERR are triggered using accordingly built input strings.