Execute method annotated with @Step outside the Allure test context #2928
Unanswered
greenenvy17
asked this question in
Questions & Support
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi everyone,
I'm wondering is it possible to execute an existing method annotated with @step outside the Allure test context in Java.
The use case i have is that i want to execute some methods as part of @BeforeAll to setup some data as Precondition because i do not want these steps to be in the Allure report. If i execute the method in @BeforeAll, i get:
AllureLifecycle - Could not start step: no test case running.I know that i can separate the logic in a different method called by the one annotated with @step and calling each when it's needed, but i'm just wondering if there is an easy way to solve this without rewriting a lot of step classes.
Thanks!
Beta Was this translation helpful? Give feedback.
All reactions