File: conftest.py

package info (click to toggle)
pytest-mpi 0.6-8
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 404 kB
  • sloc: python: 2,070; makefile: 28; sh: 22
file content (20 lines) | stat: -rw-r--r-- 526 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
from doctest import ELLIPSIS

import pytest

from sybil import Sybil
try:     # sybil >= 3
    from sybil.parsers.codeblock import PythonCodeBlockParser
except ImportError:  # sybil < 3
    from sybil.parsers.codeblock import CodeBlockParser as PythonCodeBlockParser
from sybil.parsers.doctest import DocTestParser
from sybil.parsers.skip import skip

pytest_collect_file = Sybil(
    parsers=[
        DocTestParser(optionflags=ELLIPSIS),
        PythonCodeBlockParser(),
        skip,
    ],
    pattern='*.rst',
).pytest()