Skip to content

Instantly share code, notes, and snippets.

@tomphp
Created February 15, 2015 21:30
Show Gist options
  • Save tomphp/39d2b387dd3bafb62e7c to your computer and use it in GitHub Desktop.
Save tomphp/39d2b387dd3bafb62e7c to your computer and use it in GitHub Desktop.
Feature: View a widget
# Approach 1
Scenario: View a widget's attributes
Given there is a widget named "the widget" with attribute1 "attr 1 val" and attribute2 "attr 2 val" and attribute3 "attr 3 val"
Then the widget named "the widget" should have attribute1 value "attr 1 val" and attribute2 value "attr 2 val" and attribute3 "attr 3 val"
# Approach 2
Scenario: View a widget's attributes
Given there is a widget named "the widget"
And widget named "the widget" has attribute1 value "attr 1 val"
And widget named "the widget" has attribute2 value "attr 2 val"
And widget named "the widget" has attribute3 value "attr 3 val"
Then the widget named "the widget" should have attribute1 value "attr 1 val"
And the widget named "the widget" should have attribute2 value "attr 2 val"
And the widget named "the widget" should have attribute3 value "attr 3 val"
# Approach 3
Scenario: View a widget's attribute1 value
Given there is a widget named "the widget"
And widget named "the widget" has attribute1 value "attr 1 val"
Then the widget named "the widget" should have attribute1 value "attr 1 val"
Scenario: View a widget's attribute2 value
Given there is a widget named "the widget"
And widget named "the widget" has attribute2 value "attr 2 val"
Then the widget named "the widget" should have attribute2 value "attr 2 val"
Scenario: View a widget's attribute3 value
Given there is a widget named "the widget"
And widget named "the widget" has attribute3 value "attr 3 val"
Then the widget named "the widget" should have attribute3 value "attr 3 val"
# Approach 4
# A far more elegant approach which I've not yet discovered
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment