Passed
Push — master ( 77800a...b0712d )
by Vinicius
02:58 queued 12s
created

build.tests.conftest.ev_loop()   A

Complexity

Conditions 2

Size

Total Lines 5
Code Lines 4

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
eloc 4
dl 0
loc 5
rs 10
c 0
b 0
f 0
cc 2
nop 2
1
"""Pytest conftest."""
2
import pytest
3
4
5
@pytest.fixture(autouse=True)
6
def ev_loop(monkeypatch, event_loop) -> None:
7
    """asyncio event loop autouse fixture."""
8
    monkeypatch.setattr("asyncio.get_running_loop", lambda: event_loop)
9
    yield event_loop
10