Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Test run not failing with broken tests #303

Closed
lholmquist opened this issue Aug 5, 2020 · 0 comments
Closed

Test run not failing with broken tests #303

lholmquist opened this issue Aug 5, 2020 · 0 comments
Labels
module/test Issues and changes related to the tests type/bug Something isn't working version/3.x Issues related to the 3.0 release of this library

Comments

@lholmquist
Copy link
Contributor

lholmquist commented Aug 5, 2020

Describe the Bug
While creating the PR for #301, i added a test that should fail the build. It does fail the test, but the test suite still thinks it passes. The error shows up as an unhandled promise rejection: https://github.com/cloudevents/sdk-javascript/pull/302/checks?check_run_id=951373768#step:6:330

Expected Behavior
The expected behavior is that CI should fail

Additional context
This isn't a problem with the library source code. It only happens in tests that are using promises. It could be someting with mocha and how it handles promise rejections. But that is my guess

edit: After doing a little testing, if we just add a return inside the tests, then things break/pass like a normal tets

@lholmquist lholmquist added module/test Issues and changes related to the tests type/bug Something isn't working version/3.x Issues related to the 3.0 release of this library labels Aug 5, 2020
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
module/test Issues and changes related to the tests type/bug Something isn't working version/3.x Issues related to the 3.0 release of this library
Projects
None yet
Development

No branches or pull requests

1 participant