l.t.y.setup : class documentation

Part of lp.testing.yuixhr View In Hierarchy

Decorator to mark a function as a fixture available from JavaScript.

This makes the function available to call from JS integration tests over XHR. The fixture setup can have one or more cleanups tied to it with add_cleanup decorator/callable and can be composed with another function with the extend decorator/callable.

Method __init__ Undocumented
Method __call__ Call the originally decorated setup function.
Method add_cleanup Add a cleanup function to be executed on teardown, FILO.
Method teardown Run all registered cleanups. If no cleanups, a no-op.
Method extend Undocumented
def __init__(self, function, extends=None):
Undocumented
def __call__(self, request, data):
Call the originally decorated setup function.
def add_cleanup(self, function):
Add a cleanup function to be executed on teardown, FILO.
def teardown(self, request, data):
Run all registered cleanups. If no cleanups, a no-op.
def extend(self, function):
Undocumented
API Documentation for Launchpad, generated by pydoctor at 2022-06-16 00:00:12.