Coursemology / evaluator-samples

Sample test packages for the code evaluator
0 stars 7 forks source link

Write a sample that test whether a function is a recursion. #11

Closed Teo-ShaoWei closed 7 years ago

Teo-ShaoWei commented 7 years ago

This PR addresses issue #2.

@naomilwx is this the right way place to include the function?

Fixes #2.

naomilwx commented 7 years ago

Hmm do you intend for the test to be public or private? The function name should be prefixed with test_public_ or test_private_.

Teo-ShaoWei commented 7 years ago

I think it make sense to be private. Public test is usually of the form expr == value where the student can copy as their own test case. Testing for recursion would be awkward in that form... It does however throw a helpful hint when violated. So it seems more like a private test to me.