42_EXAM
42_EXAM copied to clipboard
fprime test tries invalid inputs when the subject explicitly says the input will always be valid
subject:
The input, when there is one, will be valid.
also the subject:
Write a program that takes **A POSITIVE INT** and displays its prime factors on the...
If the program should take a positive int and the input to the program will always be valid when being tested by Moulinette, then the 42_EXAM simulator should never test fprime with a negative number.
trace for fprime:
----------------8<-------------[ START TEST
💻 TEST
./a.out "-52"
🔎 YOUR OUTPUT:
❌ TIMEOUT
----------------8<------------- END TEST
As you can see, the simulator is testing the program with an invalid input and expecting a specific result when the subject explicitly says that the program will not be tested with invalid inputs.