Skip to content

Commit

Permalink
Handle skipped tests
Browse files Browse the repository at this point in the history
Signed-off-by: Spencer Wilson <[email protected]>
  • Loading branch information
SWilson4 committed Oct 3, 2024
1 parent f958b29 commit aa67abf
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions test/oqs_test_endecode.c
Original file line number Diff line number Diff line change
Expand Up @@ -218,16 +218,24 @@ static int test_oqs_encdec(const char *alg_name) {
static int test_algs(const OSSL_ALGORITHM *algs) {
int errcnt = 0;
for (; algs->algorithm_names != NULL; algs++) {
if (test_oqs_encdec(algs->algorithm_names)) {
switch (test_oqs_encdec(algs->algorithm_names)) {
case 1:
fprintf(stderr,
cGREEN " Encoding/Decoding test succeeded: %s" cNORM "\n",
algs->algorithm_names);
} else {
break;
case -1:
fprintf(stderr,
cBLUE " Encoding/Decoding test skipped: %s" cNORM "\n",
algs->algorithm_names);
break;
default:
fprintf(stderr,
cRED " Encoding/Decoding test failed: %s" cNORM "\n",
algs->algorithm_names);
ERR_print_errors_fp(stderr);
errcnt++;
break;
}
}
return errcnt;
Expand Down

0 comments on commit aa67abf

Please sign in to comment.