Provides a decorator/context manager for enabling feature flags.
Methods are named to allow this to be used the same ways as Mock's
patches:
|
__init__(self,
flag)
x.__init__(...) initializes x; see help(type(x)) for signature |
|
|
|
start(self)
Starts the patching. |
|
|
|
stop(self)
Stops the patching. |
|
|
|
_onstr(self,
on=False)
Return the +/- representation of a boolean value. |
|
|
|
_set_ff(self,
flagname,
flagstr,
on=True)
Create the featureflag environment variable string. |
|
|
|
|
|
__exit__(self,
exc_type,
exc_value,
traceback)
Exit the context manager. |
|
|
Inherited from infra.util.DecoratorAndContextManager :
__call__ ,
decorate
Inherited from object :
__delattr__ ,
__format__ ,
__getattribute__ ,
__hash__ ,
__new__ ,
__reduce__ ,
__reduce_ex__ ,
__repr__ ,
__setattr__ ,
__sizeof__ ,
__str__ ,
__subclasshook__
|