UNPKG

1.1 kBPlain TextView Raw
1Feature: Variables
2
3 Scenario: Config Test
4
5 Given I am configured
6 And I set x = ok
7 Then I assert this.targets.google
8
9 Scenario: Scoped Var Test
10
11 Given I am scoped
12 Then I assert this.vars.x=="ok"
13
14 Scenario: Test Variable Assignment
15
16 Given I am testing dialect
17 And I set test to hello
18 Then variable test should match hello
19
20 Scenario: Test CSV sample
21
22 Given I am testing CSV parsing
23 And some CSV as test:
24 --------
25 what, who
26 hello, world
27 greetings, earthling
28 --------
29 Then $.[0].what in test should match hello
30 And $.[0].who in test should match world
31 And $.[1].what in test should match greetings
32 And $.[1].who in test should match earthling
33
34
35 Scenario: Test set body JSON sample - indirect via variable
36
37 Given I am testing JSON
38 And I set test to JSON:
39 --------
40 { "hello": "world", "earth": { "moon": "cheese" } }
41 --------
42 Then hello in test should match world
43 And earth.moon in test should match cheese
44 Then I assert this.vars.test.hello=="world"
45 And I assert this.vars.test.earth.moon=="cheese"
46
47
48