Writing Cases

Writing Cases

Write a test case in a few clicks: give it a title, fill in the details you need, then add steps. Use it to test a feature or to check a requirement.

I want to...

Do this

I want to...

Do this

Create a case

Click Create in the top bar, choose Case, enter a title and click Create or Add steps.

Add steps

Click Add steps, write the steps on the Steps tab and click Save and close.

Run a case with different data

Click Datasets on the Steps tab and add parameters.

Write a Gherkin case

Switch to BDD/Gherkin on the Steps tab. See BDD/Gherkin Cases.

Create a case

  1. Click Create in the top bar and choose Case.

  2. Fill in the Details (see the table below). Only Title is needed to start.

  3. Click Add steps at the top right of the window. The case is saved first and gets its key, for example SHOP-TC-33. Click Create instead if you want to add steps later.

  4. On the Steps tab, write your steps as a Classic case (step by step) or a BDD/Gherkin case.

  5. Click Save and close. Use Save to keep working.

The window also has Create from scenario (see BDD/Gherkin Cases), Create another to keep the window open for the next case, and Copy steps.

Case details

Field

What to enter

Field

What to enter

Title (required)

A clear name for the case.

Description

What the case is meant to check.

Preconditions

What must be true or set up before the case is run.

Folder

Pick a folder from the folder list. It starts as Not Assigned, or as the selected folder if you create the case from inside a folder. To add a folder on the spot, click the new-folder icon at the top of the list (new top-level folder) or hover a folder and click its new-folder icon (new child folder), then fill in the Add new folder window.

Owner (required)

You, by default. A case in Draft can only be owned by you, so choose another status before you assign someone else.

Priority

Helps you run the most important cases first. The field starts empty.

Status (required)

Draft (default, work in progress), Under Review, Published or Deprecated.

Type

Unit, Integration, Functional, API, Performance or Security.

Components

Components from your Jira project, to organise cases.

Releases

Releases (versions) from your Jira project.

Estimated effort

Expected execution time in the format Xh Ym, for example 1h 30m.

Tags

Free keywords that make cases easier to find. Add several. To create a tag, type its name, pick it from the list and press Enter. Tags are not case-sensitive.

Custom fields

Any custom fields set up for your project appear in their own section.

Lower part of the Create case window

A case in Draft can only be owned by you. Picking another owner shows an error. A case that is Under Review or Published cannot be moved back to Draft.

Jira requirements

Link a case to Jira requirements to build traceability. Type an issue key or summary in Search for issues and pick the issue. You can link any number of issues from several projects. To remove a link, click the unlink icon next to the issue and confirm.

Attachments

Add files that help with review, automation or writing the steps. Drag files in, click Attach files, pick from Recent uploads, or paste a screenshot with Ctrl+V (Cmd+V on Mac). All file types are allowed. Each file can be up to 100 MB. Click an attachment to view it in a window you can drag around the screen. Use the delete icon next to a file to remove it.

Automation

Field

What to enter

Field

What to enter

Status

Manual, To be Automated, In Progress or Automated. It can also be used as a workflow.

Owner

The person who automates the case. It can differ from the case owner.

Automation key

Matches the AIO Tests case with an automated test.

  • Cases written in AIO Tests first and automated later are matched by case key, for example annotate @ADP-TC-121 in the automated test. You do not need an Automation key. Supported by TestNG, Cucumber feature files and JUnit 5.

  • JUnit 4 cannot annotate directly. Put the fully qualified name (classname.methodname) in the Automation key, for example com.aio.tests.LoginTests.testPositiveLogin.

  • When a case is created automatically from automation results, the key is created on import and links the two cases.

Steps

On the Steps tab choose Classic to add steps with Data and Expected result, or BDD/Gherkin to write steps with Given, When, And, Then, But and *. In a BDD case you can also pick a Feature, and datasets are called Examples. See BDD/Gherkin Cases. Steps are needed to execute a case. The Steps tab also has AI, Link background, Datasets, Find and replace, Delete all steps and Hide data. Once a case has steps you cannot switch between Classic and BDD: remove all steps and save first.

I want to...

Do this

I want to...

Do this

Add a step

Click the plus icon on a step to add a new step below it, or press Tab while in the Expected result field.

Attach a file to a step

Click the three-dots icon on the step and choose Attach files. Paste an image or upload a document. More in Simplified Steps Writing.

Duplicate a step

Three-dots icon, then Duplicate step (Ctrl or Cmd + D). The copy appears right below the step. See Simplified Steps Writing.

Copy steps from another case

Three-dots icon on the step the new steps should follow, then Copy steps from another case. Pick a case, tick the steps you want and click Copy. They are added right after the step you chose. You can also use cases from other projects you can access. See Copy steps.

Reuse another case as a step

Three-dots icon, then Link another case. Search by key or title, switch project if needed, and click the link icon next to the case. The step becomes a linked-case row. See Reusing Cases.

Delete a step

Click the delete icon. The step is marked for deletion and removed when you save. Click the undo icon on the step to keep it.

Step menu with Attach files, Duplicate step, Copy steps from another case and Link another case

If one field of a step is filled and the other is empty, it shows Provide a value for this field and the step cannot be saved. A step with both fields empty is dropped when you save.

Datasets and parameters

Run one case with several sets of data. On the Steps tab click Datasets.

  1. Click Add parameter. On the Custom tab enter a name (up to 50 characters) and click Add. On the Predefined tab pick a predefined parameter instead. See Parameters in Cases.

  2. Click a cell in the row and enter a value. Click Add new dataset for each extra row. Drag a dataset row to reorder it. Use the three-dots icon on a row to insert a dataset below, duplicate it or delete it.

  3. Use a parameter in a step by wrapping its name in angle brackets, for example <item>. In Classic steps, typing the opening bracket shows a list of your parameter names to pick from. In BDD steps there is no list because the usual step auto-complete shows instead.

A case with datasets can include a linked case as a step. A case that has datasets cannot itself be linked into another case.

In BDD cases, Scenario Outlines with Examples map to datasets. For predefined parameters, the dataset values come from the values defined for that parameter. See Parameters in Cases.

For further queries and suggestions, feel free to reach out to our customer support via help@aiotests.com.