Raise NotImplementedError instead of NotImplemented
NotImplementedError is the name of the exception (https://docs.python.org/2/library/exceptions.html). NotImplemented is the name of a constant (https://docs.python.org/2/library/constants.html). >>> raise NotImplemented() Traceback (most recent call last): File "<pyshell#31>", line 1, in <module> raise NotImplemented() TypeError: 'NotImplementedType' object is not callable >>> raise NotImplementedError() Traceback (most recent call last): File "<pyshell#32>", line 1, in <module> raise NotImplementedError() NotImplementedError This patch fix it. Change-Id: I36292e5ee18bd792205a8ff527f4ae9705c61b61 Closes-Bug: #1339855
This commit is contained in:
parent
32af31f509
commit
5a49379b34
|
@ -29,7 +29,8 @@ class BaseStyleCheck(unit.BaseTestCase):
|
|||
|
||||
def get_checker(self):
|
||||
"""Return the checker to be used for tests in this class."""
|
||||
raise NotImplemented('subclasses must provide a real implementation')
|
||||
raise NotImplementedError('subclasses must provide '
|
||||
'a real implementation')
|
||||
|
||||
def get_fixture(self):
|
||||
return hacking_fixtures.HackingCode()
|
||||
|
|
Loading…
Reference in New Issue