You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
#143 makes a passed step with failed/broken substeps expanded by default. Still, if we collapse the parent step manually, we face the same problem: failed steps are hidden, and nothing tells us there is something wrong inside the passed step.
Moreover, Allure Awesome will keep the collapsed state if we navigate to the homepage and then go back to the test. This makes working with large tests with a complex step structure harder, especially when the report is hosted somewhere for a long time (the state persists in the browser's storage).
Use cases
Two use cases come to mind when speaking of such step structures:
Soft assertions - tests with soft assertions may represent failed assertions with failed steps. Such steps can be grouped into higher-level steps, which by default often get the passed status. Example:
Retry logic - tests may represent an attempt to, say, load some data with a step. If it takes several attempts to load the data (several failed + one succeeded), the parent step will be passed, while some substeps failed. Example:
importalluredeftest_with_soft_assertions():
withallure.step("Parent"):
forattemptinrange(0, 3):
try:
withallure.step(f"Attempt #{attempt}"):
... # code that loads the databreakexceptException:
passelse:
raiseException("Can't load the data")
Example
Given the soft assertions example above, when we generate and open the Awesome report, the test body will be shown like this:
When we collapse the Parent step, it will look like this:
Solution
Having some sort of indicator that notifies you that there are failed/broken steps inside a passed one will solve the issue. The indicator, for example, may look like a user status indicator in messengers or collaboration tools (like Slack):
Red circle: there is a failed substep inside
Yellow circle: there is a broken substep inside
Open questions
Should we limit the indication to failed/broken substeps, or should we also include skipped/unknown/passed?
Should we indicate the presence of failed/broken steps at the test level?
The text was updated successfully, but these errors were encountered:
#143 makes a passed step with failed/broken substeps expanded by default. Still, if we collapse the parent step manually, we face the same problem: failed steps are hidden, and nothing tells us there is something wrong inside the passed step.
Moreover, Allure Awesome will keep the collapsed state if we navigate to the homepage and then go back to the test. This makes working with large tests with a complex step structure harder, especially when the report is hosted somewhere for a long time (the state persists in the browser's storage).
Use cases
Two use cases come to mind when speaking of such step structures:
Example
Given the soft assertions example above, when we generate and open the Awesome report, the test body will be shown like this:
When we collapse the
Parent
step, it will look like this:Solution
Having some sort of indicator that notifies you that there are failed/broken steps inside a passed one will solve the issue. The indicator, for example, may look like a user status indicator in messengers or collaboration tools (like Slack):
Open questions
The text was updated successfully, but these errors were encountered: