WebEngine

class WebEngine extends EvalEngine[WebContext]

A web engine that uses the Selenium web driver API to automate various web operations.

class EvalEngine[WebContext]
trait GwenInfo
trait StepTranslator[WebContext]
trait UnitEngine[WebContext]
trait GherkinParser
trait StepEngine[WebContext]
trait StepDefEngine[WebContext]
trait ExamplesEngine[WebContext]
trait ScenarioEngine[WebContext]
trait RuleEngine[WebContext]
trait BackgroundEngine[WebContext]
trait SpecNormaliser
trait Interpolator
trait BehaviorRules
trait SpecEngine[WebContext]
class NodeEventDispatcher
trait LazyLogging
class Object
trait Matchable
class Any

Value members

Concrete methods

override def defaultRepeatDelay: Duration
Definition Classes
EvalEngine
override def init(options: GwenOptions, envState: EnvState): WebContext

Initialises and returns a new evaluation context.

Initialises and returns a new evaluation context.

Value parameters:
envState

the initial environment state

options

command line options

Definition Classes
EvalEngine
override def translateCompositeStep(step: Step): Option[CompositeStep[WebContext]]

Translates composite web engine steps.

Translates composite web engine steps.

Definition Classes
EvalEngine -> StepTranslator
override def translateStep(step: Step): UnitStep[WebContext]

Translates a web engine step. This method matches the incoming step against a set of supported steps and returns an operation that will evaluate those that are successfully matched.

Translates a web engine step. This method matches the incoming step against a set of supported steps and returns an operation that will evaluate those that are successfully matched.

Value parameters:
ctx

the web evaluation context

step

the step to evaluate

Definition Classes
EvalEngine -> StepTranslator

Inherited methods

def addListener(listener: NodeEventListener): Unit
Inherited from:
NodeEventDispatcher
def afterBackground(background: Background, env: Environment): Unit
Inherited from:
NodeEventDispatcher
def afterExamples(examples: Examples, env: Environment): Unit
Inherited from:
NodeEventDispatcher
def afterRule(rule: Rule, env: Environment): Unit
Inherited from:
NodeEventDispatcher
def afterScenario(scenario: Scenario, env: Environment): Unit
Inherited from:
NodeEventDispatcher
def afterSpec(result: SpecResult, env: Environment): Unit
Inherited from:
NodeEventDispatcher
def afterStep(step: Step, env: Environment): Unit
Inherited from:
NodeEventDispatcher
def afterStepDef(stepDef: Scenario, env: Environment): Unit
Inherited from:
NodeEventDispatcher
def afterUnit(unit: FeatureUnit, env: Environment): Unit
Inherited from:
NodeEventDispatcher
def beforeBackground(background: Background, env: Environment): Unit
Inherited from:
NodeEventDispatcher
def beforeExamples(examples: Examples, env: Environment): Unit
Inherited from:
NodeEventDispatcher
def beforeRule(rule: Rule, env: Environment): Unit
Inherited from:
NodeEventDispatcher
def beforeScenario(scenario: Scenario, env: Environment): Unit
Inherited from:
NodeEventDispatcher
def beforeSpec(spec: Spec, env: Environment): Unit
Inherited from:
NodeEventDispatcher
def beforeStep(step: Step, env: Environment): Unit
Inherited from:
NodeEventDispatcher
def beforeStepDef(stepDef: Scenario, env: Environment): Unit
Inherited from:
NodeEventDispatcher
def beforeUnit(unit: FeatureUnit, env: Environment): Unit
Inherited from:
NodeEventDispatcher
def callStepDef(parent: GwenNode, iStepDef: Scenario, step: Step, ctx: WebContext): Step
Inherited from:
StepDefEngine
def checkBackgroundRules(background: Background, specType: SpecType): Unit

Checks that a background satisfies behavior rules before evaluation.

Checks that a background satisfies behavior rules before evaluation.

Value parameters:
background

the background to check

specType

the spec type currently being evaluated

Inherited from:
BehaviorRules
def checkScenarioRules(scenario: Scenario, specType: SpecType): Unit

Checks that a scenario or stepdef satisfies behavior rules before evaluation.

Checks that a scenario or stepdef satisfies behavior rules before evaluation.

Value parameters:
scenario

the scenario to check

specType

the spec type currently being evaluated

Inherited from:
BehaviorRules
def checkStepDefRules(step: Step, env: Environment): Unit

Checks that a step def called in a feature satisfies behavoiur rules at evaluation.

Checks that a step def called in a feature satisfies behavoiur rules at evaluation.

Value parameters:
env

the environment context

step

the step to check

Inherited from:
BehaviorRules
def checkStepRules(step: Step, actualBehavior: BehaviorType, env: Environment): Unit

Checks that a step called in a feature satisfies behavoiur rules at evaluation.

Checks that a step called in a feature satisfies behavoiur rules at evaluation.

Value parameters:
actualBehavior

the actual behavior type of the step

env

the environment context

step

the step to check

Inherited from:
BehaviorRules
def evaluateExamples(parent: GwenNode, examples: List[Examples], ctx: WebContext): List[Examples]
Inherited from:
ExamplesEngine
def evaluateStep(parent: GwenNode, step: Step, ctx: WebContext): Step

Evaluates a step.

Evaluates a step.

Inherited from:
StepEngine
def evaluateSteps(parent: GwenNode, steps: List[Step], ctx: WebContext): List[Step]

Evaluates a list of steps.

Evaluates a list of steps.

Inherited from:
StepEngine
def evaluateUnit(unit: FeatureUnit, ctx: WebContext): Option[SpecResult]

Interprets a feature unit.

Interprets a feature unit.

Value parameters:
ctx

the evaluation context

unit

the feature unit to process

Inherited from:
UnitEngine
def finaliseStep(step: Step, ctx: WebContext): Step

Binds all accumulated attachments to the given step.

Binds all accumulated attachments to the given step.

Value parameters:
step

the step to bind attachments to

Returns:

the step with accumulated attachments

Inherited from:
StepEngine
def healthCheck(step: Step, env: Environment): Unit
Inherited from:
NodeEventDispatcher
final def interpolateParams(source: String)(resolve: String => String): String
Inherited from:
Interpolator
final def interpolateString(source: String)(resolve: String => String): String
Inherited from:
Interpolator
def interpretStep(stepExpression: String, ctx: WebContext): Try[Step]

Interprets and evaluates single step expression.

Interprets and evaluates single step expression.

Value parameters:
ctx

the evaluation context

stepExpression

the input step expression

Returns:

the evaluated step (or an exception if a runtime error occurs)

Inherited from:
StepEngine
def logStatus(options: GwenOptions, node: GherkinNode): Unit
Inherited from:
EvalEngine
def normaliseScenarioOutline(outline: Scenario, background: Option[Background]): Scenario
Inherited from:
SpecNormaliser
def normaliseSpec(spec: Spec, dataRecord: Option[DataRecord]): Spec

Normalises a parsed feature.

Normalises a parsed feature.

Value parameters:
dataRecord

optional feature level data record

spec

the feature spec

Inherited from:
SpecNormaliser
def parseSpec(feature: String, specFile: Option[File]): Try[Spec]

Produces a complete feature spec tree (this method is used to parse entire features).

Produces a complete feature spec tree (this method is used to parse entire features).

Inherited from:
GherkinParser
def parseSpec(specFile: File): Try[Spec]

Parses a Gherkin feature specification

Parses a Gherkin feature specification

Inherited from:
GherkinParser
def parseStep(step: String): Try[Step]

Produces a step node (this method is used by the REPL to read in invididual steps only)

Produces a step node (this method is used by the REPL to read in invididual steps only)

Inherited from:
GherkinParser
def removeListener(listener: NodeEventListener): Unit
Inherited from:
NodeEventDispatcher
def transitionBackground(background: Background, toStatus: EvalStatus, env: Environment): Background
Inherited from:
NodeEventDispatcher
def transitionExamples(examples: Examples, toStatus: EvalStatus, env: Environment): Examples
Inherited from:
NodeEventDispatcher
def transitionRule(rule: Rule, toStatus: EvalStatus, env: Environment): Rule
Inherited from:
NodeEventDispatcher
def transitionScenario(scenario: Scenario, toStatus: EvalStatus, env: Environment): Scenario
Inherited from:
NodeEventDispatcher
def transitionStep(step: Step, toStatus: EvalStatus, env: Environment): Step
Inherited from:
NodeEventDispatcher
def transitionSteps(steps: List[Step], toStatus: EvalStatus, env: Environment): List[Step]
Inherited from:
NodeEventDispatcher

Inherited fields

lazy val gwenHome: String
Inherited from:
GwenInfo
lazy val implHome: String
Inherited from:
GwenInfo
lazy val implName: String
Inherited from:
GwenInfo
lazy val implVersion: String
Inherited from:
GwenInfo
@transient
lazy protected val logger: Logger
Inherited from:
LazyLogging
lazy val noticeMsg: Option[String]
Inherited from:
GwenInfo
lazy val releaseNotesUrl: Option[String]
Inherited from:
GwenInfo