| 1 |
@issue |
| 2 |
Feature: Issue #159: output stream is wrapped twice in the codecs.StreamWriter |
| 3 |
|
| 4 |
@setup |
| 5 |
Scenario: Feature Setup |
| 6 |
Given a new working directory |
| 7 |
And a file named "features/steps/steps.py" with: |
| 8 |
""" |
| 9 |
# -*- coding: utf-8 -*- |
| 10 |
from behave import step |
| 11 |
|
| 12 |
@step('firstname is "{name}"') |
| 13 |
def step_impl(context, name): |
| 14 |
pass |
| 15 |
|
| 16 |
@step(u'full name is Loïc "{name}"') |
| 17 |
def step_impl(context, name): |
| 18 |
pass |
| 19 |
""" |
| 20 |
|
| 21 |
Scenario: Single feature, pass (a) |
| 22 |
Given a file named "features/issue159_stream_writer.feature" with: |
| 23 |
""" |
| 24 |
Feature: |
| 25 |
Scenario: |
| 26 |
When firstname is "Loïc" |
| 27 |
""" |
| 28 |
When I run "behave -f plain features/" |
| 29 |
Then it should pass |
| 30 |
|
| 31 |
|
| 32 |
Scenario: Single feature, pass (b) |
| 33 |
Given a file named "features/issue159_stream_writer.feature" with: |
| 34 |
""" |
| 35 |
Feature: |
| 36 |
Scenario: |
| 37 |
When full name is Loïc "Dupont" |
| 38 |
""" |
| 39 |
When I run "behave -f plain features/" |
| 40 |
Then it should pass |
| 41 |
|
| 42 |
|
| 43 |
Scenario: Two features, FAIL (a) |
| 44 |
Given a file named "features/issue159_stream_writer.feature" with: |
| 45 |
""" |
| 46 |
Feature: |
| 47 |
Scenario: |
| 48 |
When full name is Loïc "Dupont" |
| 49 |
""" |
| 50 |
And a file named "features/issue159_stream_writer_again.feature" with: |
| 51 |
""" |
| 52 |
Feature: |
| 53 |
Scenario: |
| 54 |
When full name is Loïc "Dupond" |
| 55 |
""" |
| 56 |
When I run "behave -f plain features/" |
| 57 |
Then it should pass |
| 58 |
|
| 59 |
|
| 60 |
Scenario: Two features, FAIL (b) |
| 61 |
Given a file named "features/issue159_stream_writer.feature" with: |
| 62 |
""" |
| 63 |
Feature: |
| 64 |
Scenario: |
| 65 |
When firstname is "Loïc" |
| 66 |
""" |
| 67 |
And a file named "features/issue159_stream_writer_again.feature" with: |
| 68 |
""" |
| 69 |
Feature: |
| 70 |
Scenario: |
| 71 |
When firstname is "Loïc" |
| 72 |
""" |
| 73 |
When I run "behave -f plain features/" |
| 74 |
Then it should pass |