Skip to content

Commit 07afb35

Browse files
authored
avoid double calling __del__ during self testing (via #134)
1 parent 89e7161 commit 07afb35

File tree

2 files changed

+1
-1
lines changed

2 files changed

+1
-1
lines changed

allure-behave/features/steps/behave_steps.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ def run(context, **kwargs):
4343

4444
model_runner = ModelRunner(config, [context.feature_definition])
4545
model_runner.formatters = make_formatters(config, [stream_opener])
46+
model_runner.formatters[0].listener.fixture_context.enter()
4647
model_runner.hooks = getattr(context, 'globals', dict())
4748
model_runner.run()
4849

allure-behave/src/listener.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,6 @@ def __init__(self):
3232
self.current_step_uuid = None
3333
self.execution_context = Context()
3434
self.fixture_context = Context()
35-
self.fixture_context.enter()
3635
self.steps = deque()
3736

3837
def __del__(self):

0 commit comments

Comments
 (0)