diff options
author | Oskar <> | 2024-03-21 22:38:46 +0100 |
---|---|---|
committer | Oskar <> | 2024-03-21 22:38:46 +0100 |
commit | 44beae5d68575807c65498c3f992f4a29569fb0f (patch) | |
tree | c7a844a2f3b4588a6821afddec45b5c3abed61e8 /test/validate_plus_continue_tests.c | |
parent | 18a47e78f08ef9a845a5e2f15ef9d87c0c912c58 (diff) |
i think validate_plus_continue is working now, it took way too long to figure this out
Diffstat (limited to 'test/validate_plus_continue_tests.c')
-rw-r--r-- | test/validate_plus_continue_tests.c | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/test/validate_plus_continue_tests.c b/test/validate_plus_continue_tests.c new file mode 100644 index 0000000..433dcac --- /dev/null +++ b/test/validate_plus_continue_tests.c @@ -0,0 +1,26 @@ +#include <stdlib.h> +#include <stdio.h> +#include <unistd.h> +#include <string.h> +#include <errno.h> +#include "7ed.h" +#include "i_validation.h" +#include "input.h" +#include <stdint.h> + +int main () { + uint64_t focus = 1; + char smode_buf[SMODE_MAX_SIZE]; // Smode buffer + fprintf(stdout, "(%lu): ", focus); // UI + fgets(smode_buf, SMODE_MAX_SIZE, stdin); // Read user input + + int ret = validate_plus_continue(smode_buf); + + if(ret == _INVALID) { + printf("?\n"); + } + if(ret == _VALID) { + printf("valid\n"); + } + +}
\ No newline at end of file |