Skip to content

Commit

Permalink
Make transfer_markers a noop when importing fails
Browse files Browse the repository at this point in the history
  • Loading branch information
Tadaboody committed Jan 6, 2019
1 parent e868913 commit 2c8023d
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion pytest_asyncio/plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,12 @@
import socket

import pytest
from _pytest.python import transfer_markers
try:
from _pytest.python import transfer_markers
except ImportError: # Pytest 4.1.0 removes the transfer_marker api (#104)
def transfer_markers(*args, **kwargs): # noqa
"""Noop when over pytest 4.1.0"""
pass

try:
from async_generator import isasyncgenfunction
Expand Down

0 comments on commit 2c8023d

Please sign in to comment.