WebUI tests: Make possible to use kwargs with @screenshot decorator

Reviewed-By: Petr Cech <pcech@redhat.com>
This commit is contained in:
Serhii Tsymbaliuk
2018-10-22 09:23:04 +02:00
parent 8f2a75cb00
commit 8954521007

View File

@@ -95,9 +95,9 @@ def screenshot(fn):
Should be applied on methods of UI_driver subclasses Should be applied on methods of UI_driver subclasses
""" """
@wraps(fn) @wraps(fn)
def screenshot_wrapper(*args): def screenshot_wrapper(*args, **kwargs):
try: try:
return fn(*args) return fn(*args, **kwargs)
except unittest.SkipTest: except unittest.SkipTest:
raise raise
except Exception: except Exception: