Python 3.10 is now available in preview.

google.appengine.runtime.context.ctx_test_util.isolated_context

Decorates a test function or class to run itself in a clean context.

When used with a class, it will run each test function in its own context. It will also run setUp, tearDown, and doCleanups in that context by default.

*args See _isolated_context_class and _isolated_context_callable.
**kwargs See _isolated_context_class and _isolated_context_callable.

The raw function decorator.