-
Notifications
You must be signed in to change notification settings - Fork 61
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
Rule proposal: no same level suites and tests #104
Comments
@fleg What would be the rationale for such a rule? Is it purely stylistic or are there any problems with having suites and tests at the same level? |
stylistic I guess |
actually mocha do not preserve order for same level suites and tests describe('root', function() {
it('a', function() {});
it('b', function() {});
describe('bar', function() {
it('x', function() {});
it('y', function() {});
});
it('q', function() {});
it('w', function() {});
});
|
Regarding the order of the output of mochas spec reporter, there is already #35 which is a proposal to enforce the same order in the test code. Anyway I would be ok with I rule that forbids to have tests at the same level as suite. The only thing I wonder if this should be a separate rule than the one suggested in #35 or if they have enough things in common that it could be one generic rule? |
I think it could be one rule with option to forbid same level tests/suites |
Bad
Good
The text was updated successfully, but these errors were encountered: