Skip to content
| Marketplace
Sign in
Visual Studio Code>Testing>DICED CucumberNew to Visual Studio Code? Get it now.
DICED Cucumber

DICED Cucumber

forest-of-london

|
119 installs
| (0) | Free
An In-house DICE.FM extension to run our Ruby Cucumber tests from feature files and within the Visual Studio Code sidebar.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

DICED Cucumber Extension

DICED Cucumber, is an In-house DICE.FM extension for running our Ruby Cucumber tests directly from Visual Studio Code. This extension enables you to run tests from feature files and view the results in the sidebar.


Table of Contents

  1. Features
  2. Download
  3. Usage
    • Running Tests
    • Menu Options
    • Reports
  4. Configuration
  5. Requirements
  6. Contribution
  7. How to Build

Features

  • Run Cucumber Tests: Execute your Ruby Cucumber tests directly from VS Code.
  • Sidebar Integration: View and manage your tests from the sidebar.
  • Context Menu Options: Quickly run or refresh tests from the context menu.
  • Detailed Reports: View detailed test reports within VS Code.
  • HTML Reports: Generate and view HTML reports with links in the output channel.
  • Run Links in Feature Files: Run tests directly from the feature files using small "Run Test" links added above each detected scenario or scenario outline example.
  • Rerun Last Test: Easily rerun the last executed test using a keybinding.

Usage

Running Tests

There are several ways to run your Ruby Cucumber tests using the DICED Cucumber extension:

  1. From the Sidebar:

    • Click on the "Testing" icon in the sidebar to open the test explorer.
    • Select the test or test suite you want to run and click the play button.
  2. From Feature Files:

    • Small "Run Test" links are added above each detected scenario or scenario outline example. Click these links to run the individual test.
  3. From the Context Menu:

    • Right-click on a .feature file or inside an open .feature file.
    • Select ► Cucumber Feature to run all tests within it.
  4. Rerun Last Test:

    • Press Ctrl+Shift+i (Windows/Linux) or Cmd+Shift+i (macOS) to rerun the last executed test.
  5. Automatically on Save:

    • Configure your settings to run tests automatically whenever you save a .feature file.

Menu Options

The extension introduces new options in various menus:

  1. Explorer Context Menu:

    • ► Cucumber Feature: Run the selected feature file.
    • ↺ Cucumber Features: Refresh the test list.
    • ✖ Cancel Running Cucumber Tests: Cancel all running tests.
  2. Editor Context Menu:

    • ► Cucumber Feature: Run the feature file currently open in the editor.
    • ↺ Cucumber Features: Refresh the test list.
    • ✖ Cancel Running Cucumber Tests: Cancel all running tests.

Reports

After running tests, view detailed reports within VS Code:

  1. Test Explorer:

    • View the status of each test, including passed, failed, and skipped tests.
    • Click on individual tests to see detailed results or jump to their location in their feature file.
  2. Output Channel:

    • View logs and output of your test runs in the Output panel.
    • HTML reports are generated for each test run, providing detailed results. Links to these reports are available in the output channel.
  3. Message Box:

    • After each test run, a message box will notify you if the HTML report is generated, with a link to open it directly.
  4. Show Logs Link:

    • After a test run, refreshing the tests will display a "Show Logs" link, allowing you to view the detailed logs for the test runs.

Configuration

  1. "diced-cucumber.rootDirectory":

    • Description: This setting specifies the path to the directory containing the "features" folder where your Cucumber tests are located. (If you are not using 'chrome_docker')
    • Example: If your project directory is located at "/path/to/your/project", you should set this value to "/path/to/your/project", ensuring to include the starting "/".
  2. "diced-cucumber.domain":

    • Description: This setting determines the value of the DOMAIN environment variable used during test execution.
    • Example: To run your tests on a domain named "example-domain.com", set this value to "example-domain.com".
  3. "diced-cucumber.browser":

    • Description: This setting specifies the browser to use for running the tests. The selected browser value is used to set the ENV['BROWSER'] environment variable when running tests.
    • Options: "chrome" or "chrome_docker"
    • Default: "chrome"
  4. "diced-cucumber.headless":

    • Description: This setting controls whether to run the tests in headless mode. If enabled, the "headless" option is passed to ChromeDriver through Capybara. (If you are not using 'chrome_docker')
    • Options: true or false
    • Default: false
{
  "diced-cucumber.domain": "example-domain.com",
  "diced-cucumber.rootDirectory": "/path/to/your/project",
  "diced-cucumber.browser": "chrome",
  "diced-cucumber.headless": false
}

Requirements

  • Visual Studio Code (v1.89.0 or higher)
  • vscode-test-explorer extension (automatically installed)
  • ibm.output-colorizer extension (automatically installed)

Contribution

Contributions are welcome! Please submit issues or pull requests in the GitHub repository.


How to Build

  1. Clone the Repository: Clone the DICED Cucumber repository.
  2. Install Dependencies: Run npm install to install all required dependencies.
  3. Build the Extension: Run npm run build to compile the TypeScript files.
  4. Package the Extension: Run npm run package to create the VSIX package.
  5. Install the Extension: Install the generated VSIX file in Visual Studio Code.

Happy Testing!

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2025 Microsoft