Skip to content
Snippets Groups Projects
Commit 13d6914f authored by Bouillaguet Charles's avatar Bouillaguet Charles
Browse files

amélioration critère test_falsenegative

parent 8db7a322
Branches
No related tags found
No related merge requests found
...@@ -62,10 +62,13 @@ int main() ...@@ -62,10 +62,13 @@ int main()
printf("1..1\n"); printf("1..1\n");
static const int nbtests = 1000000; static const int nbtests = 1000000;
int successes = testValid(f, nbtests); int successes = testValid(f, nbtests);
if (successes != nbtests) bool ok = (known_low == 11) && (successes > 0.635*nbtests);
printf("not ok 1 - #success = %d / %d\n", successes, nbtests); ok |= (known_low == 12) && (successes > 0.99*nbtests);
ok |= (known_low == 13) && (successes == nbtests);
if (ok)
printf("ok 1 - %d tests OK\n", nbtests);
else else
printf("ok 1 - all %d tests OK\n", nbtests); printf("not ok 1 - #success = %d / %d\n", successes, nbtests);
exit(0); exit(0);
} }
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment