exclusive#

exclusive(*, when: str | dict[str, str] | None = None) None#

Do not run this test in parallel with any other test.

Usage#

.pyt:

import canary
canary.directives.exclusive(*, when=...)

.vvt: NA

Parameters#

  • when: Restrict processing of the directive to this condition

The when expression is limited to the following conditions:

  • testname: Restrict processing of the directive to this test name

  • platforms: Restrict processing of the directive to certain platform or platforms

  • options: Restrict processing of the directive to command line -o options

  • parameters: Restrict processing of the directive to certain parameter names and values

Examples#

import canary
canary.directives.exclusive(when="platforms='not darwin'")