1
0
mirror of https://github.com/openSUSE/osc.git synced 2025-02-04 02:26:16 +01:00

- GET decorator: use name of the original method for the wrapper method

This commit is contained in:
Marcus Huewe 2010-08-24 19:06:49 +02:00
parent 5b6aa0a4fc
commit 71e0b3ee34

View File

@ -54,6 +54,9 @@ def GET(fullurl, **kwargs):
def wrapped_test_method(*args):
addExpectedRequest('GET', fullurl, **kwargs)
test_method(*args)
# "rename" method otherwise we cannot specify a TestCaseClass.testName
# cmdline arg when using unittest.main()
wrapped_test_method.__name__ = test_method.__name__
return wrapped_test_method
return decorate