Skip to content

nth-prime: Make exercise schema-compliant #665

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Mar 9, 2017
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 23 additions & 16 deletions exercises/nth-prime/canonical-data.json
Original file line number Diff line number Diff line change
@@ -1,34 +1,41 @@
{
"#": [
"exercise": "nth-prime",
"version": "1.0.0",
"comments": [
"The tests that expect 'false' should be implemented to raise",
"an error, or indicate a failure. Implement this in a way that",
"makes sense for your language."
],
"cases": [
{
"description": "first prime",
"input": 1,
"expected": 2
"description": "first prime",
"property": "prime",
"input": 1,
"expected": 2
},
{
"description": "second prime",
"input": 2,
"expected": 3
"description": "second prime",
"property": "prime",
"input": 2,
"expected": 3
},
{
"description": "sixth prime",
"input": 6,
"expected": 13
"description": "sixth prime",
"property": "prime",
"input": 6,
"expected": 13
},
{
"description": "big prime",
"input": 10001,
"expected": 104743
"description": "big prime",
"property": "prime",
"input": 10001,
"expected": 104743
},
{
"description": "there is no zeroth prime",
"input": 0,
"expected": false
"description": "there is no zeroth prime",
"property": "prime",
"input": 0,
"expected": false
}
]
}