2. Specification
By Example
Behaviour
Driven
Development
Acceptance
Test Driven
Development
3. You want to do X,
and you think Y is the best way of doing so.
Instead of asking about X,
you ask about Y.
4. You want to do deliver the right software,
and you think SpecFlow is the best way of doing so.
Instead of asking about Specification By Example,
you ask about SpecFlow.
5. How can we stop these scenarios being so brittle?
How do we use our BDD tool to do <this kind of testing>?
We’re using a BDD tool. How do we get our analysts to help us?
How can we avoid all this duplication in our scenarios?
What do we do if the business aren’t interested in BDD?
6.
7.
8.
9.
10. 1.1 - Two firm orders in the market, existing implied calendar order
h4. *Given*
* the following orders already exist:
| ID | Contract | Existing Order |
| 1 | <contract 1> | <order 1> |
| 2 | <contract 2> | <order 2> |
h4. *When*
* I subscribe to implied orders for <observed contract>
* The following orders are added:
|| ID || Contract || Added Order ||
| A | <contract A> | <order A> |
h4. *Then*
* I should observe the following implied orders:
|| Contract || Implied Order ||
| <observed contract> | <implied order> |
11. h4. *Examples*
|| contract 1 || order 1 || contract A || order A || observed contract || implied order ||
| API2 - Jul 2010 | Bid 5@10 | API2 - Aug 2010 | Ask 5@10 | API2 - Jul 2010 x Aug 2010 | Bid 5@0 |
| API2 - Jul 2010 | Bid 5@20 | API2 - Aug 2010 | Ask 5@10 | API2 - Jul 2010 x Aug 2010 | Bid 5@10 |
| API2 - Jul 2010 | Bid 5@20 | API2 - Aug 2010 | Ask 5@30 | API2 - Jul 2010 x Aug 2010 | Bid@-10 |
| API2 - Jul 2010 | Ask 5@10 | API2 - Aug 2010 | Bid 5@10 | API2 - Jul 2010 x Aug 2010 | Ask 5@0 |
| API2 - Jul 2010 | Ask 5@20 | API2 - Aug 2010 | Bid 5@10 | API2 - Jul 2010 x Aug 2010 | Ask 5@10 |
| API2 - Jul 2010 | Ask 5@20 | API2 - Aug 2010 | Bid 5@30 | API2 - Jul 2010 x Aug 2010 | Ask 5@-10 |
| API2 - Jul 2010 x Aug 2010 | Bid 5@0 | API2 - Aug 2010 | Bid 5@5 | API2 - Jul 2010 | Bid 5@5 |
| API2 - Jul 2010 x Aug 2010 | Ask 5@0 | API2 - Aug 2010 | Ask@5 | API2 - Jul 2010 | Ask 5@5 |
| API2 - Jul 2010 x Aug 2010 | Bid 5@5 | API2 - Aug 2010 | Bid 5@5 | API2 - Jul 2010 | Bid 5@10 |
| API2 - Jul 2010 x Aug 2010 | Ask 5@5 | API2 - Aug 2010 | Ask@5 | API2 - Jul 2010 | Ask 5@10 |
| API2 - Jul 2010 x Aug 2010 | Bid 5@-5 | API2 - Aug 2010 | Bid 5@5 | API2 - Jul 2010 | Bid 5@0 |
| API2 - Jul 2010 x Aug 2010 | Ask 5@-5 | API2 - Aug 2010 | Ask@5 | API2 - Jul 2010 | Ask 5@0 |
12. Scenario: [2.B] First leg is generated when orders already exist on the second leg and the spread.
Given the following orders already exist:
| ID | Contract | Existing Order |
| AB | <contract A> - <contract B> | <order AB> |
| B | <contract B> | <order B> |
Then I should observe these implied orders:
| Source | Contract | Implied Order |
| AB+B | <contract A> | <implied order> |
Examples:
| order AB | order B | implied order |
| Bid (0,5]@0 | Bid (0,5.5]@10 | Bid (0,5]@10 |
| Ask (0,5]@0 | Ask (0,5]@5 | Ask (0,5]@5 |
Examples:
| contract A | contract B |
| "API 2" "Nov 2010" | "API 2" "Dec 2010" |
| "API 2" "Nov 2010" | "API 4" "Nov 2010" |
| ("API 2" "Nov 2010" - "API 4" "Nov 2010") | ("API 2" "Dec 2010" - "API 4" "Dec 2010") |
19. Scenario: Change propagates from a value cell to a reference via 3 references
Given a sheet with data:
| Row | A | B | C | D | E |
| 1 | 1 | =A1 | =B1 | =C1 | =D1 |
When the values are changed:
| Cell | Value |
| A1 | 2 |
Then the values should equal:
| Cell | Value |
| E1 | 2 |
20. Scenario: Sum from 3 horizontal cells
Given a sheet with data:
| Row | A | B | C | D |
| 1 | 1 | 10 | 100 | =<formula> |
When the cell values are computed
Then the values should equal:
| Cell | Value |
| D1 | 111 |
Examples:
| formula |
| A1+B1+C1 |
| SUM(A1,B1,C1) |
| SUM(A1:C1) |
| SUM(C1:A1) |