-
Notifications
You must be signed in to change notification settings - Fork 16
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
Print module docstrings in spec output #28
Comments
👍 |
1 similar comment
+1 |
Neat idea; I haven't run into this need myself because the projects I've been testing end up organized into one test module per class under test, so the "top level" of the test output is naturally pretty distinct/unique. But I can see why testing similar collections of functionality would make the output harder to parse. Would need to make sure this is actually feasible re: how Nose organizes discovered tests (I haven't poked at that part of Spec in a year or so, so memory hazy) but given I was able to get the rest of things indented it's probably doable somehow. I'd definitely consider merging a PR implementing this, otherwise I may pok when I have time. |
Excellent. I'll have a go at implementing. |
I would find it useful if the spec output included the module docstring as well. This would let me set some context for the following TestCases.
Example
For example, for functional tests I end up naming my TestCases things like:
which outputs as:
But the trouble is I end up with lots of TestCases with the same name and the spec output is a little confusing.
Proposal
It would be good if I could use a module docstring to distinguish between test modules. Eg:
would lead to something like:
The underlining is optional. It might be better to use a bold font or simply leave it to the docstring to distinguish the module docstrings.
Sensible?
The text was updated successfully, but these errors were encountered: