mocha-github-actions-reporter icon indicating copy to clipboard operation
mocha-github-actions-reporter copied to clipboard

how can Mocha help?

Open boneskull opened this issue 3 years ago • 7 comments

Hi,

Thanks for this project! Mocha's about to merge a change that runs our CI on GitHub Actions, and we're using this reporter. I'm wondering if there's anything we could do to provide a better API for you--I see that you have to process some line numbers, for example--could we make this easier?

Mocha can also offer to maintain this module in the future, if you no longer have interest.

boneskull avatar Oct 07 '20 22:10 boneskull

I'm not responsible for this project, but exposing the error values as a property on the error would be a great improvement. The parsing of the stack trace finds the file, line, and column for errors. If those were exposed instead, that would allow the deletion of the parsing functionality and greatly simplify the code.

fearphage avatar Oct 20 '20 14:10 fearphage

I can look into this, but without some intent to use whatever we provide, it's much less likely to get done...

boneskull avatar Oct 20 '20 16:10 boneskull

I mean I'm more than happy to send a PR to make use of new properties. What happens after that is beyond my control of course.

fearphage avatar Oct 20 '20 18:10 fearphage

Hey all! :wave:

Some properties to avoid the stack trace parsing would be great and I'd really like to see that. I'd be happy to take PRs for this project but if someone gives me a ping, I can also look at updating things myself :slightly_smiling_face:

daniellockyer avatar Oct 22 '20 15:10 daniellockyer

@boneskull Any updates from the Mocha side?

fearphage avatar Oct 21 '21 13:10 fearphage

I am quite interested about the subject as seeing mocha failures as annotations can really improve the UX on reviews. Do we have a project already using this in production?

ssbarnea avatar Jan 31 '22 12:01 ssbarnea

@ssbarnea The official Mocha project uses it 🙂 https://github.com/mochajs/mocha/blob/cc51b8fb42c4919e1304724bdb1a90699d17cf85/.github/workflows/mocha.yml#L158-L159

daniellockyer avatar Jan 31 '22 22:01 daniellockyer