File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -323,7 +323,10 @@ def _(site):
323
323
324
324
325
325
def test_variable_reuse (pytester ):
326
- """Test example parameter reuse."""
326
+ """
327
+ Test same example parameter name used for step args between calls
328
+ doesn't redefine example arg value.
329
+ """
327
330
328
331
pytester .makefile (
329
332
".feature" ,
@@ -358,18 +361,22 @@ def test_variable_reuse(pytester):
358
361
def some_key_exists(key):
359
362
print(f"some {key} exists")
360
363
364
+
361
365
@when(parsers.parse('I print {css_id}'))
362
366
def css_id(css_id):
363
367
assert css_id in ('bar', 'bar2')
364
368
369
+
365
370
@when(parsers.parse('I echo {css_id}'))
366
371
def echo_val(css_id):
367
372
assert css_id in ('bar', 'bar2')
368
373
374
+
369
375
@when(parsers.re('I output "(?P<css_id>.+)"'))
370
376
def i_output(css_id):
371
377
assert css_id == 'some value'
372
378
379
+
373
380
@then('finish testing')
374
381
def i_output():
375
382
print("finished")
You can’t perform that action at this time.
0 commit comments