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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Continue execution after failed stage #711

Open
KenStorey opened this issue Sep 9, 2021 · 3 comments
Open

Continue execution after failed stage #711

KenStorey opened this issue Sep 9, 2021 · 3 comments

Comments

@KenStorey
Copy link

Is it possible to instruct Tavern not to stop executing a test when it encounters a failure?

Most of our tests are of the form

  • Set up
  • Perform test
  • Tear down

If a failure is encountered the tear down does not happen and, consequently, subsequent tests all fail.

@michaelboulton
Copy link
Member

I don't think there's any particular reason why there couldn't be something like

setup:
	- name: ...

stages:
	- name: step 1
	- name: step 2

teardown:
	- name: ...

Where the teardown would act like a 'finally' block in Python and would always run as long as the setup stages all finished

@hamx0r
Copy link
Contributor

hamx0r commented Dec 1, 2021

Is anyone working on this? I could use this feature too and will write it if no one else is working on it.

@lvijnck
Copy link
Contributor

lvijnck commented Apr 11, 2022

I would opt to add a new keyword to each test step, eg., execute that can take up values always or success. Analogous to how GitHub does it. We could have it set to success by default. WDYT @michaelboulton?

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

4 participants