-
-
Notifications
You must be signed in to change notification settings - Fork 27
exercises: provide stubs for every exercise #474
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
Conversation
|
CI log when stubs passed checks: Example CI log when bad stubs failed checks: |
|
I was hoping to finish this a long time ago. Now that it's Mechanical March already, I'd like to merge this soon. Requested reviewers: could either of you check that the stubs look reasonable? I'll keep this as draft until I've fixed the names in CI does check that every exercise has a test file and stub that:
|
ErikSchierboom
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fabulous!
Before this commit, the user-facing solution file was empty for every exercise apart from: - clock - hello-world - react Add initial content to the user-facing solution file for every other exercise. Closes: 409
And for now: - Implement this outside `check_exercises.nim`. - Don't optimize by combining the tests for every exercise stub. This simplifies checking that running each individual test file produces an error when using the stub.
Reflect the changes from commit 53d7803.
I'm not convinced that it's worth requiring the user to add this themselves.
Try to communicate the idea slightly better. We might consider making both parameters required, but let's leave that for later. Otherwise, I think it's better to avoid writing `stop = start`, so the user can discover that for themselves, or be mentored on that point.
Before this commit, the user-facing solution file was empty for every exercise apart from:
clockdnd-characterhello-worldreactAdd initial content to the user-facing solution file for every other exercise.
And check in CI that every exercise has a test file and stub that:
Unfortunately, for now, this significantly increases the time taken to run CI (for the fastest exercises job: from about 25 seconds to about 4 minutes).
Closes: #409
Closes: #410
To-do:
Some things left to consider:
lasagnaparameters to match the docsTablevsCountTablevs arrayrangetypes?actions/cachecheck_stubs.nimwhen one of these files changes:check_stubs.nimitself, an exercise stub, or an exercise test filecheck_stubs.nimrun only on Linuxcheck_stubs.nimrun via a separate workflowPolicies:
proc, notfuncFor later PRs: