Verify the Behavior Testing Framework for ContactManager installation

About this task

Check that you installed the framework correctly. You can do this by: (1) verifying that the appropriate directories and files have been added, (2) running a base configuration feature file, and (3) running a base configuration suite.

The scenarios provided in Behavior Testing Framework will pass when executed against a stand-alone base configuration instance of ContactManager. If the instance has been integrated with other Guidewire applications or configured, some tests may not pass.

Procedure

  1. Open Guidewire Studio.
  2. Optionally verify that the following directories and files exist:
    • In configuration/gsrc/gw/api/test, an ABSmokeTestClassBase.
    • A configuration/gsrc/gw/smoketest.pl directory.
    • A configuration/gtest/gw/cucumber directory.
    • A configuration/gtest/gw/enhancement directory.
    • In configuration/gtest/gw/suites, an ABExampleSmokeSuite file.
    • A configuration/gtest/gw/smoketest directory.
    • In configuration/res/cucumber, a DuplicateContactsBatchExample.feature file.
  3. Test a base configuration feature file.
    The feature file assumes that ContactManager has not been configured. When run on a base configuration of ContactManager, all scenarios in the feature file will pass. If ContactManager has been configured, one or more scenarios may fail.
    1. Navigate to configuration/res/cucumber.
    2. Right-click the DuplicateContactsBatchExample.feature file, and then click Run 'Feature: DuplicateContactsBatchExample'.
    Studio opens a Run Feature <FeatureName> tab. The left pane contains icons that identify the tests that pass or fail. The right pane contains a console with the server output during testing.
  4. Test a base configuration suite.
    A suite is a collection of feature files that are executed together. The suite assumes that ContactManager has not been configured. When run on a base configuration of ContactManager, all scenarios in the suite will pass. If ContactManager has been configured, one or more scenarios may fail.
    There is a known issue with Behavior Testing Framework that prevents a test suite from running if there is a running test server. As a workaround, if there is a running test server, stop it before executing the following steps.
    1. Navigate to configuration/gtest/gw/suites.
    2. Right-click the ABExampleCucumberSuite file, and then click Run 'ABExampleCucumberSuite'.
    Studio opens a Run <SuiteName> tab. The left pane contains icons that identify the tests that pass or fail. The right pane contains a console with the server output during testing.