Simplify failure output
See original GitHub issueWith:
import test from 'ava';
test('returns true when happy', t => {
throw new Error('unicorn');
});
It currently outputs:
❯ ava
1 failed
returns true when happy
Error: unicorn
Test.fn (test.js:5:8)
I think we should simplify it to:
❯ ava
1 failed
returns true when happy
Error: unicorn
test.js:5:8
So users can quickly see where the error came from. Test.fn
doesn’t have any value to the user.
This also applies to the verbose reporter ($ ava --verbose
).
We could also use https://github.com/sindresorhus/ansi-escapes#itermsetcwdpath to make the path clickable on iTerm.
Issue Analytics
- State:
- Created 7 years ago
- Reactions:3
- Comments:13 (11 by maintainers)
Top Results From Across the Web
Simplify test failure output · Issue #518 · wix/Detox - GitHub
I would be interested in contributing to Detox to simplify the test failure output, if it's interesting and nobody is already working on...
Read more >Simplifying and Isolating Failure-Inducing Input - CS@Purdue
Abstract—Given some test case, a program fails. Which circumstances of the test case are responsible for the particular failure? The Delta Debugging.
Read more >Simplifying Failure-Inducing Input
Our goal is now to simplify the failing test case C—that is, to min-. imize it. ... the output is still wrong; if...
Read more >Simplifying and Isolating Failure-Inducing Input
The function rtest : R → {✓,✘,?} determines for a program run r∈R whether some specific failure occurs (✓) or not (✘) or...
Read more >Print Quality Guide | Simplify3D Software
We have compiled an extensive list of the most common 3D printing issues along with the software settings that you can use to...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Only partly. The current output looks like:
As you can see, the test file and line are shown twice. I think we could simplify it to not show the stack trace if it’s only the test function. @avajs/core Thoughts?
I can take care of this as I’ve worked with the reporters before.