Cucumber Integration Extension for Polarion ALM

This Polarion extension is designed to integrate BDD process into Polarion. It provides the almost same functionality as Xray plugin for Jira:

Important

Starting from version 2.0.0 only latest version of Polarion is supported. Right now it is Polarion 2606.

Quick start

The latest version of the extension can be downloaded from the releases page and installed to Polarion instance without necessity to be compiled from the sources. The extension should be copied to <polarion_home>/polarion/extensions/ch.sbb.polarion.extension.cucumber/eclipse/plugins and changes will take effect after Polarion restart.

Important

Don't forget to clear <polarion_home>/data/workspace/.config folder after extension installation/update to make it work properly.

Polarion configuration

Cucumber feature editor to appear on Test Case page

  1. Open a project which Test Case pages should display the editor
  2. On the top of the project's navigation pane click ⚙ (Actions) ➙ 🔧 Administration. Project's administration page will be opened.
  3. On the administration's navigation pane select Work Items ➙ Form Configuration.
  4. On the form configuration page you will see 2 sections: Form Filters and Form Layouts.
  5. In the table of Form Layouts section find line Test Case and click 📝 Edit
  6. In opened Form Layout Configuration editor find a line with code:
    …
    <field id="description"/>
    …
    
  7. Insert following new line after it:
    …
    <extension id="cucumber" label="Cucumber Test"/>
    …
    
  8. Save changes by clicking 💾 Save

Cucumber feature editor to appear on the Live Doc sidebar

  1. Open a project which the Live Doc sidebar should display the editor
  2. On the top of the project's navigation pane click ⚙ (Actions) ➙ 🔧 Administration. Project's administration page will be opened.
  3. On the administration's navigation pane select Documents & Pages ➙ Work Item Properties Sidebar.
  4. In the opened Edit Project Configuration editor insert the following line:
    …
    <extension id="cucumber" label="Cucumber Test"/>
    …
    
  5. Save changes by clicking 💾 Save

Test Run's description to appear on UI

By default, Test Run's UI doesn't display its description (as a custom field). To enable displaying description following needs to be done:

  1. Open a project which Test Run Templates needs to be modified.
  2. In Navigation, click Test Runs. The Test Runs page opens. The top section of the page displays a table of existing Test Runs.
  3. On the right hand side of the toolbar of the Test Runs page, click Manage Templates. The table of Test Runs is replaced by a table of Test Run Templates.
  4. Select a template you want to modify.
  5. On the toolbar of the detail pane, click ⚙ (Actions) ➙ Customize Test Run Page.
  6. You will see a warning block containing text:

    This is a Test Run template, you cannot execute this test. Please create a Test Run first using this template

  7. Click ✎ (Pencil) to edit code of this block, on the right hand side of the page you will see following lines of code:
    #if($testRun.fields().isTemplate().get())
      $widgetContext.renderWarning("<b>This is a Test Run template</b>, you cannot execute this test. Please create a Test Run first using this template")
    #end
    #if($testRun.fields().records().is().empty() && $testRun.fields().selectTestCasesBy().optionId().equals("manualSelection"))
      $widgetContext.renderInfo("Select the test cases you want to plan for execution by clicking Operations > Select Test Cases.")
    #end
    
  8. Add new lines:
    …
    #if(!$testRun.fields().description().is().empty())
      $testRun.fields.description.render().withText()
    #end
    
  9. Save template by clicking 💾

Custom fields: Components

  1. Create an enum containing all acceptable components names for selected project:
  2. Create a custom field for selected project:
  3. Customize Test Run Report to show Components field:

Custom fields: Test Plan

  1. Create a custom field for selected project :
  2. Customize Test Run Report to show Test Plan field:
  3. Customize Plan to show links to Test Runs:

Custom field: Team-SBB

  1. Create an enum containing all acceptable team names for selected project:
  2. Create a custom field which will keep the value (this step can be made in global configuration, but global fields will be visible only if the local configuration for test runs is deleted https://community.sw.siemens.com/s/question/0D54O00007Fh7iLSAR/do-global-test-run-custom-fields-work-locally):
  3. Customize Test Run Report to show Team-SBB field:

REST API

This extension provides REST API. OpenAPI Specification can be obtained here.