How to use the allure-behave.src.hooks.AllureHooks function in allure-behave

To help you get started, we’ve selected a few allure-behave examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github allure-framework / allure-python / allure-behave / src / hooks.py View on Github external
def allure_report(result_dir="allure_results"):
    allure_hooks = AllureHooks(result_dir)
    frame = inspect.currentframe()
    try:
        for hook_name in HOOKS:
            if hook_name in frame.f_back.f_locals:
                frame.f_back.f_locals[hook_name] = wrapper(frame.f_back.f_locals[hook_name],
                                                           getattr(allure_hooks, hook_name))
            else:
                frame.f_back.f_locals[hook_name] = getattr(allure_hooks, hook_name)
    finally:
        del frame

allure-behave

Allure behave integration

Apache-2.0
Latest version published 8 months ago

Package Health Score

74 / 100
Full package analysis

Similar packages