What is a custom field
Custom Field is an attribute of a test case or a test result used to provide the meta information about your tests. It is not an independent entity.
For automated tests custom fields are transferred from your tests to Allure TestOps using Labels.
Examples of the meta information provided with help of a custom field could be Test Suite, Feature, Microservice, name of your test framework, name of the programming language used to write your automated tests, name of the creator/maintainer of a test.
How Allure TestOps uses custom fields
There are four main ways to use the information from the custom fields in Allure TestOps:
- Building custom analytics.
- Filtering the tests results and test cases.
- Create test plans based on filters.
Before we can start using the information from Custom Fields, we need to configure Global custom fields and mapping of your custom fields to the global ones.
Grouping - trees
Allure TestOps uses Custom Fields information to build trees to represent the test cases or test results.
During the deployment Allure TestOps will create three default views for the test cases and test results - flat view, Suites, Features.
- Flat view will contain no grouping and this is similar to how Allure TestOps stores test cases in its database.
- Suites tree contains suites and test cases.
- Features tree contains features, stories and test cases.
Suite, Feature, and Story are custom fields provided from your test cases and/or test results.
You can create a new tree
The information from the custom fields can be used to adjust the analytics widgets to your needs.
Using Allure TestOps’ built-in query language you can change the information displayed in the widgets.
Filtering test results or test cases
- In the test cases section or in Tree tab of a launch activate the filtering by clicking on the Funnel button.
- Click +
- In Custom fields area select any of the values of a custom field.
- Filter will be applied.
Create test plans based on Custom fields
To create a test plan that will be dynamically updated, you need to do the following.
- In the test cases section apply a filter as was shown in previous section.
- Select all test cases visible based on the filter.
- Click on bulk actions button and select create test plan.
- Name the test plan.
Adding custom fields to manual tests
In the test cases section do the following:
- Select a manual test case.
- Locate Fields section and click Edit button (looks like a pencil).
- In the modal window select from the drop-down the name of a custom field.
- Add needed Value and then click Submit button.
Adding custom fields to automated tests
The work with custom fields and automated test is excessively described in the section dedicated to the Labels. Section covers everything you need to know.