Selective test documentation creation

Modified on Tue, 7 Mar, 2023 at 10:17 AM

In a situation when it is required that the result of the autotest execution after Launch closing does not lead to the fact that the associated manual test case would become automated because the work on this test case has not yet been completed and its results do not meet expectations and it cannot be used in runs. For these types of situations, we have two possible solutions


Solution #1


Configuring AQL Documentation Update Rules (this solution was created in the system precisely for such type of situations)


Based on AQL for Launches (https://docs.qameta.io/allure-testops/advanced/aql/launches/) each Launch has information from the CI/CD system, such as Names and Tags, so we can update the test documentation or ignore its update using this information:


Example #1

Test documentation updates on the main branch


Example #2

By Tags. Test documentation updates only if there is no "skip-live-doc" tag in the Launch Tags


Example #3

By Name. Test documentation updates only for Launches with the "Launch at" substring in the Launch Name


Solution #2


Use AS_ID = -1

Example for Java (@AllureId("-1"))

@Test
@AllureId("-1")
//@AllureId("123324")
@Microservice("Billing")
@Story("Create new issue")
@Tags({@Tag("web"), @Tag("critical")})
@DisplayName("Creating new issue by authorised user")
public void shouldCreateIssue() {
    steps.openIssuesPage(OWNER, REPO);
    steps.createIssueWithTitle(ISSUE_TITLE);
    steps.shouldSeeIssueWithTitle(ISSUE_TITLE);
}


In this solution, the result will be marked as Orphaned and no test case will be updated and will not become automated until the correct AllureId is specified for it. 


Note: Please consider Solution #1 as the main solution method. It has a higher chance to avoid human factor mistakes.

Was this article helpful?

That’s Great!

Thank you for your feedback

Sorry! We couldn't be helpful

Thank you for your feedback

Let us know how can we improve this article!

Select at least one of the reasons

Feedback sent

We appreciate your effort and will try to fix the article