-
-
Notifications
You must be signed in to change notification settings - Fork 6.5k
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
Feature: Purposefully failing test (test.failing) #4627
Comments
Another example is you encounter a bug that you cannot fix at the moment. Instead of skipping it, marking it as
|
Just wanted to comment to maybe bring back some attention to his feature. I myself find it extremely useful, especially for documentation purposes and I think it wouldn't hurt for Jest to have it. I miss it when switching from an AVA project! |
Would be great if the default reporter output the number of intentionally failing tests similar to how we do .todo now 👍 |
I added my vote on this feature, which is also available on RSpec (https://relishapp.com/rspec/rspec-core/v/3-8/docs/pending-and-skipped-examples/pending-examples). One additional use case would be in a Test-Commit-Revert (TCR) context: I might want to write the test first and not implement the feature yet, so I mark it as |
This issue is stale because it has been open for 1 year with no activity. Remove stale label or comment or this will be closed in 30 days. |
Bump |
PR welcome! 🙂 Looking at how |
@SimenB I can jump into implementing it. I even tried already but I've stumbled upon 1 problem. |
Thanks @michalwarda! I don't think we need to add this to jasmine |
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Do you want to request a feature or report a bug?
Feature
What is the current behavior?
As discussed in #1605, ava has a way of marking a test purposefully failing. I'd like to replicate that feature in Jest. The other features mentioned in #1605 has been implemented for more than a year, so I'm making a new issue to track
test.failing
.I'll try to find the time to implement this the coming week.
If the current behavior is a bug, please provide the steps to reproduce and either a repl.it demo through https://repl.it/languages/jest or a minimal repository on GitHub that we can
yarn install
andyarn test
.N/A
What is the expected behavior?
I should be able to have a test that is failing on purpose (due to a bug or a non-implemented feature) that only fails the test suite if the test passes.
Link to Ava's docs on the feature: https://github.com/avajs/ava/blob/42e7c74c46756c441fe33ecdcbb76ac210e422ea/readme.md#failing-tests
Please provide your exact Jest configuration and mention your Jest, node, yarn/npm version and operating system.
N/A
The text was updated successfully, but these errors were encountered: