-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
Add ability to run only one(focused) example #3911
Conversation
9099919
to
80f8524
Compare
Generated by 🚫 Danger |
80f8524
to
d52f802
Compare
Codecov Report
@@ Coverage Diff @@
## master #3911 +/- ##
==========================================
- Coverage 92.61% 92.56% -0.06%
==========================================
Files 436 436
Lines 21964 21990 +26
==========================================
+ Hits 20343 20355 +12
- Misses 1621 1635 +14
📣 Codecov can now indicate which changes are the most critical in Pull Requests. Learn more |
I like the idea of focusing on specific examples. Commenting out all but the relevant examples finds an end with this. I wonder, though, whether it can be made sure that code with focused examples is not checked in. There could be a custom SwiftLint rule which checks for |
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.
Thanks, this will be helpful!
Ah yes Danny's suggestion would be good to consider. I'd be ok if we had a custom rule preventing this from being checked in. |
d52f802
to
5b8cd25
Compare
@jpsim is there any additional env that is set on CI? |
@jpsim how about allowing this functionality under |
ebb1b71
to
6f08114
Compare
6f08114
to
937f31f
Compare
@jpsim @SimplyDanny |
Co-authored-by: JP Simard <jp@jpsim.com>
Co-authored-by: JP Simard <jp@jpsim.com>
* Add ability to focus on a specific test example * Update CHANGELOG.md Co-authored-by: JP Simard <jp@jpsim.com> * Update CONTRIBUTING.md Co-authored-by: JP Simard <jp@jpsim.com> Co-authored-by: JP Simard <jp@jpsim.com>
Adds helper method, that allows marking only one example to be run when running tests
Sometimes, when specific rule example is debugged, it is really helpful to run one 'test'/'example'.
This PR adds ability to mark Examples that need to be checked when running tests
i.e.
In case if multiple examples marked as 'focused', then all of them will be checked when running tests.
This PR is inspired by the same functionality in other testing frameworks:
https://github.com/Quick/Quick/blob/72e9afa98f00c719b16c359d67d95366bad0a460/Documentation/en-us/QuickExamplesAndGroups.md#temporarily-running-a-subset-of-focused-examples