Our documentation site has been updated to AIO Tests Knowledge Base
Creating Cases
To give a better understanding of the system, throughout the documentation, we shall explain the features with help of the ATM Machine example. With an ATM Machine, a user can withdraw, deposit, get inquiries whereas the bank can validate card and pin number. Based on the same, user will be guided to create a new Test Case.
This article explains how to create cases in AIO Tests.
- 1 Create new case
- 1.1 Details
- 1.1.1 Basic Information
- 1.1.2 Jira Requirements
- 1.1.3 Automation
- 1.1.4 Attachments
- 1.2 Steps
- 1.2.1 Classic Case
- 1.2.2 BDD Case
- 1.3 Data Parameterization/Examples Based Cases
- 1.1 Details
Create new case
A new Test Case can be created from the top navigation bar by clicking on the Create drop-down and selecting the “Case” option.
Below screen is displayed on click of Create Case button. A new case can be created by adding details and optionally adding steps as explained in detail below.
Details
The first step is to add details of the case to be created. User can enter basic information, map the case to Jira Requirements, add automation attributes and attachments. If custom fields are created for cases, they will appear in its own section after Jira Requirements section.
Basic Information
Following fields are available to be filled up
Title: The user can give a relevant name to a Test Case. It is a mandatory field
Description: The user can use this field to describe the objective of the case.
Preconditions: User should mention the prerequisites that must be fulfilled prior to executing the test. They specify the setup needed for a Case to be executed successfully
Folder: The folder drop-down shows the folder structure for cases. If user clicked ‘Create Case’ from All Cases then it will pre-populate with “Not Assigned”. If user clicked “Create Case” from within a folder then it will pre-populate with the selected folder’s name. The test case will then be created in selected folder
Owner: The logged in user’s name is pre-populated as Owner. User can change owner only if status is other than Draft
Priority: Prioritization ensures the most important test cases are executed first. By default priority is Not Assigned
Status: AIO Tests has 4 statuses for Test cases – Draft, Under Review, Published and Deprecated. Draft is selected by default which means a case is “work-in-progress”
Type: AIO Tests supports - Unit, Integration, Functional, API, Performance and Security testing. User can use these to categorize the cases
Component: With AIO Tests, components that were created in Jira (by user), becomes available while creating a case. This feature helps to categorize and organize cases
Release: Releases that were created (based on the delivery dates) in Jira, becomes available while creating a case
Estimated Effort: The expected time to complete the execution of the case can be entered in the given format Xh Ym
Tags: Tags are keywords that let you classify cases in a more flexible and informal manner. They help you in system wide searching. You can associate multiple tags to your case. To create a new tag, start entering the tag name in the field and press enter once done
The Test cases in Draft (Status) cannot be owned by other users
Tags are not case sensitive
You cannot move a Test Case from Under Review/Published to Draft status.
Jira Requirements
AIO Tests allows to map cases to Jira requirements for creating traceability while creating a case. Users can search and link any number of Jira requirements from multiple projects to a case.
Users can enter Jira issue key or Jira issue summary to search for the requirement and upon selecting the requirement, it will get linked to the case
To unlink a requirement from a case, the highlighted unlink button can be used
Automation
There are three attributes that support Automation currently
Status: Users can specify the automation status. It can be used as a workflow too
Manual
To be Automated
In Progress
Automated
Owner: The user responsible for automating the case can be specified here. This field can be different from the Case Owner field
Automation Key: Automation key helps to match AIO Tests cases with an automated case
For cases, which are first written in AIO Tests and then automated, the match can be established by key e.g. by annotating @ADP-TC-121 in the automated case and Automation key need not be used. [supported by TestNG, Cucumber feature, JUnit 5]
For the specific case of JUnit 4, which does not support annotating directly, the link can be established by putting the Fully Qualified name (classname.methodname) in the automation key value e.g. com.aio.tests.LoginTests.testPositiveLogin
For cases, where the case is being created automatically from automation results, this key becomes the link between the automated case and the AIO Tests case - it is automatically created while importing results
Attachments
While creating a case, user has the option to attach any necessary files that may help the case review, automation or the steps to be written.
Multiple files can be attached via the “Attach File(s)” link
All file types are allowed but the size limit is 100 MB
An attached file can be deleted from the case by clicking ‘Delete’ icon next to the attached file
After filling in the fields, you can click on “Create Case” to use the Case afterwards or you can also Click “Add Steps”, and wizard will take you to the next page for adding steps.
Create Case: The current window will close with a success message and the user will be navigated back to the cases listing. The success message contains the link of the newly created case using which the user can go the Case Details page
Add Steps: The Steps page is shown along with a success message that the case has been created. The next section discusses the Steps page
Steps
The below window is shown on click of “Add Steps” from the Create Case window. Users have the option to create a Classic case (step-by-step) or a BDD case (Gherkin).
Classic Case
Classic case will allow users to add Steps along with Data and Expected Results to the case. Steps are necessary for execution of a case. While writing steps, few functions can be done like
Add new step: Clicking the plus symbol or clicking ‘Tab’ key while on ‘Expected Results’ field adds a new line below the current step allowing user to enter steps to execute the case
Attach File: Clicking on the ellipsis gives the user an option to add attachments at the step level (in addition to the case level). Users can either paste an image or upload documents. Find more details here
Duplicate a step: Clicking on the ellipsis gives the user an option to duplicate a step which copies the data from the step above into the step being created
Copy Steps: Clicking on the ellipsis gives the user an option to copy steps already written for other cases into the case they are on. Users can also add steps from cases of other projects that they have access to. Find more details on Copy steps here
Link another case: Clicking on the ellipsis and then clicking the link symbol changes the current step into a step with a linked case allowing user to search for an existing case by key or title and link it to the case being created. Users can also link cases from other projects that they have access to. This promotes reusability across cases and across projects and saves time and effort
Delete a step: Clicking the delete symbol will allow the user to delete a particular step. The step isn’t deleted permanently but is marked for deletion. The actual deletion takes place on the click of Save Steps
If steps or expected results field is left blank, an error message stating “Please provide a value for this field” will be shown.
BDD Case
Clicking on BDD/Gherkin option will allow users to add Steps in Gherkin language using keywords → Given, When, And, Then, But and *. More details on BDD cases can be found here.
Click “Save and Close” button to complete the process of creating a new Case. A success message is displayed as shown below. The success message contains the link of the newly created case using which the user can go the Case Details page.
The users have the option to hide the data column and expand the box that they are writing in. Users can also click “Details” tab to go back to the initial screen and update any details, if required.
Data Parameterization/Examples Based Cases
Users can choose to parameterize their cases and run them with several datasets by clicking on the Datasets icon while editing a Case.
Creating Datasets/Examples
In BDD cases, Scenario Outlines can map to such Example Based cases
Click on + icon to Add New Parameters
Once parameters required have been created, datasets can be created by clicking on the row cells.
Users can choose to define as many datasets as required. Datasets can be reordered, deleted and modified.
Using Parameters in Steps
To use parameters in steps, the parameter names need to be enclosed in angular brackets : <>
For classic cases, user will be shown a prompt with a list of parameter names
For BDD cases, user can use the parameter in a similar way, however, there will be no prompt of parameter names due to an auto-complete dropdown coming for existing steps.
Data Sets in Linked Cases
If a case is linked to another case, datasets cannot be created for such cases
Cases which have datasets defined cannot be linked to cases and would show the linking button as disabled :