| 1 |
#!/usr/bin/env python |
| 2 |
# -*- coding: utf-8 -*- |
| 3 |
""" |
| 4 |
Support functionality to simplify the setup for behave tests. |
| 5 |
|
| 6 |
.. sourcecode:: python |
| 7 |
|
| 8 |
# -- FILE: features/environment.py |
| 9 |
from behave4cmd0.setup_command_shell import setup_command_shell_processors4behave |
| 10 |
|
| 11 |
def before_all(context): |
| 12 |
setup_command_shell_processors4behave() |
| 13 |
""" |
| 14 |
|
| 15 |
from __future__ import absolute_import |
| 16 |
from .command_shell import Command |
| 17 |
from .command_shell_proc import BehaveWinCommandOutputProcessor |
| 18 |
|
| 19 |
def setup_command_shell_processors4behave(): |
| 20 |
Command.POSTPROCESSOR_MAP["behave"] = [] |
| 21 |
for processor_class in [BehaveWinCommandOutputProcessor]: |
| 22 |
if processor_class.enabled: |
| 23 |
processor = processor_class() |
| 24 |
Command.POSTPROCESSOR_MAP["behave"].append(processor) |