Skip to content
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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature]: Including the Hooks in the jest.retryTimes #15002

Open
manojvenkatap opened this issue Apr 3, 2024 · 1 comment
Open

[Feature]: Including the Hooks in the jest.retryTimes #15002

manojvenkatap opened this issue Apr 3, 2024 · 1 comment

Comments

@manojvenkatap
Copy link

馃殌 Feature Proposal

I want to include the jest hooks (boforeAll,beforeEach,afterEach,afterAll) when the test is failed.

Motivation

the hooks are helpful to reduce the repetitive code that we write in each step. If the hooks are not included as part of the retry the tests block code will have lot of repetitive code and there will be lot of maintenance on the tests.

Example

I am going to verify the checkout step with the following tests. And after each tests I am reloading the page using afterEach hook
Test 1: Want to verify the checkout steps are visible
Test 2: Want to verify the current step is marked with a tag as active

for both the tests i will be using an hook beforeEach to navigate till the checkout page.
if the test 2 is failed due to some it will execute the afterEach, beforeEach and the test

Pitch

Config

Copy link

github-actions bot commented May 3, 2024

This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 30 days.

@github-actions github-actions bot added the Stale label May 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant