Create New Project Wizard - Add BDD Files Page

Applies to TestComplete 15.69, last modified on November 13, 2024

With TestComplete, you can create and automate BDD tests. On the Add BDD files page of the New Project wizard, you can specify the feature files to be imported to your new test project. You can then automate their test steps in the project.

To view the page, select the BDD files check box on the first page of the wizard, and then click Next there.

The 'Add BDD files' page

Click the image to enlarge it.

You can add feature files stored on your hard drive (you can import, for example, the feature files you created for Cucumber), import BDD scenarios from CucumberStudio, or create new feature files.

Import a project from CucumberStudio

CucumberStudio (formerly known as HipTest) is a cloud-based testing platform by SmartBear. You can import BDD tests from CucumberStudio into your test project and automate them with TestComplete. For more information on this, see CucumberStudio Integration.

To import feature files:

  1. Select Import a project from CucumberStudio.

  2. Specify the credentials you use to connect to CucumberStudio.

    If you are not a CucumberStudio client, click Create a new CucumberStudio account and follow subsequent instructions. You will get a free CucumberStudio account. Specify the email and password then on the page.

    If you log in to CucumberStudio by using your GitHub or Google account, generate API credentials in CucumberStudio, and then specify them in the wizard. See Login With GitHub or Google Credentials for details.

    Select the Remember login credentials check box to command TestComplete to save the credentials on your computer. TestComplete will use them for your further operations with HipTest. If you keep the check box clear, you will have to enter the credentials every time TestCompletesynchronizes feature files with CucumberStudio, or posts test results to CucumberStudio.

    Click Next.

  3. On the next page, the wizard will ask you to specify a CucumberStudio project from which BDD scenarios should be imported:

    The 'Import feature files from a CucumberStudio project' page

    Click the image to enlarge it.

    Note: CucumberStudio supports both BDD and non-BDD test projects. You need to select a BDD CucumberStudio project. To make the choice easier, the wizard hides non-BDD projects from the page.

    Select the desired project and click Finish.

What happens next

TestComplete will import feature files from the specified CucumberStudio project and create project items for them in the new test project. If CucumberStudio feature files are organized into folders and subfolders, TestComplete will clone the folder structure in its project. TestComplete will also generate script functions for all the test steps in the imported feature files and will link the test steps to these functions (so, you will not have to do this manually later). To automate BDD tests, you will have to create code for these script functions.

By default, your TestComplete project becomes bound to the CucumberStudio project. This means that TestComplete will automatically update its feature files from CucumberStudio every time you open your project in TestComplete, or before you run BDD tests in TestComplete. TestComplete will also store results of automated test runs to CucumberStudio/

For more information on this, see CucumberStudio Integration. Note that you can import feature files from CucumberStudio at any time by binding your existing TestComplete project to a CucumberStudio project.

Add local BDD feature files

You can append existing feature files to your new TestComplete project. These files should have the .feature extension and should be written in Gherkin.

  1. Select Add local BDD feature files.

  2. Click the ellipsis button and browse for the folder that contains the feature files you want to add to your TestComplete project.

    BDD adepts typically have multiple feature files stored in some folder and subfolders. With TestComplete, you can import all these files at a time.

  3. Click Finish.

What happens next

TestComplete will scan the specified folder and its subfolders for the .feature files and will include these files in the new TestComplete project you are creating. Also, it will automatically generate script functions for test steps in the imported feature files, so you will not have to do this manually. To automate BDD scenarios, you then need to create or record code for these functions.

Create a new feature file

You can create a new feature file and add it to your TestComplete project:

  1. Select Create a new feature file.

  2. Click Finish.

What happens next

TestComplete will create a new project and add a stub feature file to it.

See Also

Create New Project Wizard
Create BDD Scenarios

Highlight search results