Gwen Workspaces

Setting up Gwen for teams just got a whole lot easier!

Manually setting up and installing Gwen on multiple machines or build servers in a team environment can be tedious and can also result in inconsistent configurations across workstations. One of the reasons why we created gwen-gpm was to provide consistent installation across machines and platforms. But a team needs more than that. A team needs a consistent and seamless way of getting Gwen configured and running on any user workstation or build server too.

Introducing Gwen workspaces

Gwen workspaces solve this problem by defining a standard project structure on the file system complete with settings files and wrapper scripts that can easily be committed to Git and checked out on any machine. Any team member can then just checkout the workspace and start using Gwen straight away. Gwen and the native web drivers will be automatically downloaded and installed on any user workstation or build server if they are not already present (through an embedded Gwen package manager in the workspace).

It is assumed that the target browser is already installed on the system. If not, you will need to manually install it. The wrapper script installs Gwen and native drivers but not the browser itself.

The structure of this workspace is defined as follows:

gwen-workspace
|--/env                   : Put environment properties here
|--/features              : Put your Gherkin feature files here
|--/meta                  : Put your Gwen meta files here
|  gwen                   : Gwen launcher/wrapper script for linux
|  gwen.bat               : Gwen launcher/wrapper script for windows
|  gwen.properties        : Common Gwen properties
|  log4j.properties       : Gwen log settings
|  gwen-gpm.properties    : Downloadable package checksums
|  gwen-gpm.jar           : Gwen package manager
|  .gitignore             : Git ignore file

Create and Commit a Workspace to Git

To create a Gwen workspace for your team, perform the following (only one person in the team needs to do this):

  • Download and extract the latest gwen-workspace.zip to a location on your file system. (Also have a read of the README.txt file that is extracted in the root).
  • Tweak or add team wide settings to the gwen.properties file in the workspace root. You can also tailor the wrapper scripts if necessary (for example, if you want to change the default Gwen launch options or add some new ones).
  • Verify that it all works by launching gwen (on windows) or ./gwen (on linux). Type exit when done to quit the REPL session.
  • Commit and push the workspace to your remote Git repository (see online Git help if you are not sure how to do this)

Checkout Workspace from Git and Go..

To use the workspace on any machine, perform the following (all team members need to do this):

  • Ensure that the target browser is installed on the system
  • Checkout the workspace from Git
  • Open a command prompt to the root workspace location
  • Type..
    • gwen (on windows) or ./gwen (on linux) followed by the options you require
    • Gwen will execute using the settings in the workspace
      Note: this same command can be used on any build server that checks out the workspace too
    • Gwen and native web drivers will self install on the first call
    • Type exit when done to quit the REPL session (if you started Gwen in REPL mode).

The team can now manage all their Gwen settings, environment configurations, Gherkin feature files, and Gwen meta files in a single workspace that can easily be pulled down and executed on any machine.

Help

For help, open a command prompt in the workspace root and type:

  • gwen help (on windows platforms)
  • ./gwen help (on linux platforms)

Each folder in the workspace also includes a README.txt file that can help to guide you.

Advertisements

Gwen Package Manager

Gwen just got a package manager that you can use to consistently manage your installations of the following packages across platforms:

The primary benefits of using this when working with Gwen include:

  • All downloads and installs are managed for you
  • You can easily update to the latest versions of packages
  • You can easily switch between versions of packages
  • All downloads are verified for integrity before they are installed
  • Installation is consistent across platforms

Read all about it here and check it out. We’ve just released version 1.0.0. Please provide feedback so we can address any issues and make it better.

Gwen Supports Full Gherkin Syntax

With the recent addition of Data Tables and Doc Strings, Gwen now supports the full Gherkin syntax! We’ve also enhanced the REPL console with a paste mode to enable multi-line step evaluation. The latest web engine has been released with all the new capabilities.

This is a major milestone for Gwen. Thank you to all the users who raised issues or requests and to everyone who evaluated the web engine and provided feedback. It really helps us to keep making Gwen better when we hear from you. 🙂