Backport test id decorator for forwards/backwards compat
Bug #1538269 reported by
Ryan Lane
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Bandit |
Incomplete
|
Wishlist
|
Tim Kelsey |
Bug Description
Unreleased version of bandit requires a decorator that specifies a test number. If it isn't added, then bandit won't run a test; however, that decorator isn't available in older versions of bandit, so when the new version of bandit is released all old plugins will immediately be incompatible.
If the decorator is backported, plugins can add the decorators and be forwards/backwards compatible.
Changed in bandit: | |
assignee: | nobody → Tim Kelsey (tim-kelsey) |
To post a comment you must log in.
Alternatively 3rd party plugins (however few exist) can just do
try: core.test_ properties import test_id
return func
from bandit.
except ImportError:
def test_id(banditid):
def identity(func):
return identity
To get the same effect without declaring an actual test id on your test function.