# Generate test cases in BDD format

You can now generate test cases in Gherkin format directly within the app. This eliminates the need to manually write or convert test cases into Gherkin format and saving a lot of time.

When creating a test case, you can choose between two styles:

* **Classic (default)**
* **Gherkin**

To generate a test case in Gherkin format, first select creation of a test with AI Copilot.

<figure><img src="https://3920520305-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FyZbW8vbNs5hz8x57emJJ%2Fuploads%2FPk646eV0Y5zyb8deePtz%2Fimage.png?alt=media&#x26;token=9aa97114-5e3c-4822-9961-8a56ca3493d9" alt=""><figcaption></figcaption></figure>

* Once the modal opens, select based on what you want to generate a test case and then choose the **Gherkin** style from the available options.
* **Single or Multiple test cases**:
  * If **Single** is selected, you can specify a path (e.g., negative/positive).
  * If **Multiple** is selected, you can generate multiple test cases simultaneously. The behavior is consistent with the classic test case creation process.

<figure><img src="https://3920520305-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FyZbW8vbNs5hz8x57emJJ%2Fuploads%2FmfAzhR8CnkrMjSzoMbia%2Fimage.png?alt=media&#x26;token=e048ae19-db83-46e2-b49a-2e51b5a71c8b" alt=""><figcaption></figcaption></figure>

Once generation begins, you’ll see all the test cases being created in real-time.

<figure><img src="https://3920520305-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FyZbW8vbNs5hz8x57emJJ%2Fuploads%2FgnuY6ju9GliqUfrJ9yGK%2Fimage.png?alt=media&#x26;token=06126c40-e16b-4028-acd4-5d035ec75938" alt=""><figcaption></figcaption></figure>

When AI Copilot completes the process, you can preview each test case and decide whether to keep it, regenerate it, or discard it.

<figure><img src="https://3920520305-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FyZbW8vbNs5hz8x57emJJ%2Fuploads%2FGFpIYjUxn2suFi184Kdl%2Fimage.png?alt=media&#x26;token=1a88028c-e53e-471b-b7a8-5b126f1308a7" alt=""><figcaption></figcaption></figure>

Need to tweak something? Simply provide additional instructions, and AI Copilot will regenerate the test case based on your updated input.

<figure><img src="https://3920520305-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FyZbW8vbNs5hz8x57emJJ%2Fuploads%2FlIsWP8zuUDzpuqUSyHuZ%2Fimage.png?alt=media&#x26;token=10cbda98-c7be-4006-93a9-44e59ad8947e" alt=""><figcaption></figcaption></figure>

In the preview mode you can't edit a test case, but later you can modify it on the test case page

<figure><img src="https://3920520305-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FyZbW8vbNs5hz8x57emJJ%2Fuploads%2Fg37vqYTgfPhYrPNDu2qk%2Fimage.png?alt=media&#x26;token=3eef93a0-5b40-454a-a0b1-290f99e92b02" alt=""><figcaption></figcaption></figure>

To remove a test case from the list, just uncheck the selection icon.

<figure><img src="https://3920520305-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FyZbW8vbNs5hz8x57emJJ%2Fuploads%2F53r3JsYDZdmunF4N9vdK%2Fimage.png?alt=media&#x26;token=03798212-65e3-4842-86d4-78db47070ee0" alt=""><figcaption></figcaption></figure>

Once you are done with a review, simple click on the 'Save' button.

All test cases will be added to your project.
