Skip to content

Installation

Richard Tomlinson edited this page Feb 22, 2017 · 12 revisions

The JBehave plug-n for Designer gives syntax highlighting and content assist when you open stories. While not necessary to author and execute JBehave test, it makes for a more productive and intuitive experience.

Note that Designer 9.0 and earlier will not work with the JBehave plugin. Run it in a regular vanilla Eclipse or a 9.5 or later version of Designer.

Pre-requisits

Ensure you've deployed the wm-aop framework and made the changes necessary as described on the Installation within Integration Server page.

Adding the plugin to Designer

Start Designer then:

  • From the menu bar, select Help then Install New Software...
  • Click the Add... button
  • Enter a name of: JBehave
  • Add the the new site location of http://jbehave.org/reference/eclipse/updates/ and click OK Adding JBehave as a location
  • Select the JBehave feature Selecting the JBehave feature
  • Follow standard Eclipse installation procedure (Next -> Next -> I accept.... -> Finish) and restart Designer when prompted

Configuring the JBehave plug-in

JBehave when used for Java development, looks in the project folders for classes that are configured for JBehave tests. The plugin needs to look for the wm-jbehave test runner that will execute the stories.

Once installed, configure the plug-in within Designer by going to the menu bar and:

  • Select Window followed by Preferences
  • On the left of the pane click on JBehave and select Class Scanner
  • In the filter pattern, enter org.wmaop.bdd.jbehave and click the Include button below. After clicking the button, you can drag the slider on the scroll box above to verify its been added to the bottom of the list Example of story highlighted by plug-in
  • Click OK to finish the configuration

The purpose of this configuration is so that files under src/test/resources ending in .story are recognised and shown with a different icon:

Example of story folder

And when opened, stories will appear with the same icon in the editor and have highlighted text

Example of story highlighted by plug-in