dsl

package
v1.0.0-...-2e13a7c Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 2, 2014 License: MIT Imports: 3 Imported by: 0

Documentation

Overview

Package dsl uses Ginkgo to implement a Capybara-like DSL for writing acceptance tests. This package is provided entirely for convenience. This DSL is not required to write Ginkgo acceptance tests using the core and matchers packages. Unlike the core package, the dsl package only permits a single running WebDriver.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Background

func Background(body interface{}, timeout ...float64) bool

Background is equivalent to Ginkgo BeforeEach.

func Check

func Check(selection core.Selection)

Check is comparable to Expect(selection.Check()).To(Succeed())

func Click

func Click(selection core.Selection)

Click is comparable to Expect(selection.Click()).To(Succeed())

func CreatePage

func CreatePage(browserName ...string) core.Page

CreatePage creates a new session using the current running WebDriver. For Selenium, the browserName determines which browser to use for the session.

func CustomPage

func CustomPage(capabilities core.Capabilities) core.Page

CustomPage creates a new session with a custom set of desired capabilities using the current running WebDriver. The core.Use() function may be used to generate this set of capabilities. For Selenium, the capabilities Browser(string) method sets which browser to use for the session.

func DoubleClick

func DoubleClick(selection core.Selection)

DoubleClick is comparable to Expect(selection.DoubleClick()).To(Succeed())

func FFeature

func FFeature(text string, body func()) bool

FFeature is equilavent to Ginkgo FDescribe (Focused Describe).

func FScenario

func FScenario(description string, body func(), timeout ...float64) bool

FScenario is equivalent to Ginkgo FIt (Focused It).

func Feature

func Feature(text string, body func()) bool

Feature is equivalent to Ginkgo Describe.

func Fill

func Fill(selection core.Selection, text string)

Fill is comparable to Expect(selection.Fill(text)).To(Succeed())

func PFeature

func PFeature(text string, body func()) bool

PFeature is equilavent to Ginkgo PDescribe (Pending Describe).

func PScenario

func PScenario(description string, ignored ...interface{}) bool

PScenario is equivalent to Ginkgo PIt (Pending It).

func Scenario

func Scenario(description string, body func(), timeout ...float64) bool

Scenario is equivalent to Ginkgo It.

func Select

func Select(selection core.Selection, text string)

Select is comparable to Expect(selection.Select(text)).To(Succeed())

func StartChrome

func StartChrome()

StartChrome starts a ChromeDriver WebDriver service for use with CreatePage.

func StartPhantomJS

func StartPhantomJS()

StartPhantomJS starts a PhantomJS WebDriver service for use with CreatePage.

func StartSelenium

func StartSelenium()

StartSelenium starts a Selenium WebDriver service for use with CreatePage.

func Step

func Step(text string, callbacks ...func())

Step is equivalent to Ginkgo By.

func StopWebdriver

func StopWebdriver()

StopWebdriver stops the current running WebDriver.

func Submit

func Submit(selection core.Selection)

Submit is comparable to Expect(selection.Submit()).To(Succeed())

func Uncheck

func Uncheck(selection core.Selection)

Uncheck is comparable to Expect(selection.Uncheck()).To(Succeed())

func XFeature

func XFeature(text string, body func()) bool

XFeature is equilavent to Ginkgo XDescribe (Pending Describe).

func XScenario

func XScenario(description string, ignored ...interface{}) bool

XScenario is equivalent to Ginkgo XIt (Pending It).

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL