| Index: verification/base.py
|
| diff --git a/verification/base.py b/verification/base.py
|
| index 4ca196580d32324412c1932e90816db39b0be136..7f2349eb045b5f717cb7d02667190fde49297835 100644
|
| --- a/verification/base.py
|
| +++ b/verification/base.py
|
| @@ -28,13 +28,7 @@ class DiscardPending(Exception):
|
|
|
| class Verified(model.PersistentMixIn):
|
| """A set of verifications that are for a specific patch."""
|
| - persistent = [
|
| - 'verifications',
|
| - ]
|
| -
|
| - def __init__(self):
|
| - super(Verified, self).__init__()
|
| - self.verifications = {}
|
| + verifications = dict
|
|
|
| def pending_name(self):
|
| raise NotImplementedError()
|
| @@ -73,13 +67,7 @@ class Verified(model.PersistentMixIn):
|
|
|
| class IVerifierStatus(model.PersistentMixIn):
|
| """Interface for objects in Verified.verifications dictionary."""
|
| - persistent = [
|
| - 'error_message'
|
| - ]
|
| -
|
| - def __init__(self, error_message=None):
|
| - super(IVerifierStatus, self).__init__()
|
| - self.error_message = error_message
|
| + error_message = (None, str)
|
|
|
| def get_state(self):
|
| """See Verified.get_state()."""
|
| @@ -92,13 +80,10 @@ class IVerifierStatus(model.PersistentMixIn):
|
|
|
| class SimpleStatus(IVerifierStatus):
|
| """Base class to be used for simple true/false verifiers."""
|
| - persistent = IVerifierStatus.persistent + [
|
| - 'state',
|
| - ]
|
| + state = int
|
|
|
| - def __init__(self, state=PROCESSING, error_message=None):
|
| - super(SimpleStatus, self).__init__(error_message)
|
| - self.state = state
|
| + def __init__(self, state=PROCESSING, **kwargs):
|
| + super(SimpleStatus, self).__init__(state=state, **kwargs)
|
|
|
| def get_state(self):
|
| return self.state
|
|
|