Ref #5273: doctest: add test for skipif calling global setup/cleanup

Ensure that `doctest_global_setup` and `doctest_global_cleanup` are executed
before and after evaluating each `:skipif:` option.
This commit is contained in:
Antti Kaihola
2018-08-16 17:56:29 +03:00
parent d52488f028
commit 098f37fddf
2 changed files with 30 additions and 18 deletions

View File

@@ -7,4 +7,10 @@ exclude_patterns = ['_build']
doctest_global_setup = '''
from test_ext_doctest import record
record('doctest_global_setup', 'body', True)
'''
doctest_global_cleanup = '''
record('doctest_global_cleanup', 'body', True)
'''