Skip to content

Commit

Permalink
Merge pull request #7143 from drew2a/fix/7125/selector
Browse files Browse the repository at this point in the history
Revert #6527
  • Loading branch information
drew2a authored Nov 4, 2022
2 parents fa4ab6b + 45bb11f commit fcea30e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 20 deletions.
Original file line number Diff line number Diff line change
@@ -1,14 +1,6 @@
import asyncio

import pytest


@pytest.fixture
def event_loop():
# We use a SelectorEventLoop on all platforms so our test suite should use a similar event loop.
return asyncio.SelectorEventLoop()


def pytest_addoption(parser):
parser.addoption('--tunneltests', action='store_true', dest="tunneltests",
default=False, help="enable tunnel tests")
Expand Down
15 changes: 3 additions & 12 deletions src/tribler/core/conftest.py
Original file line number Diff line number Diff line change
@@ -1,32 +1,29 @@
import asyncio
import os
import os
import sys
from pathlib import Path
from unittest.mock import MagicMock

import pytest
from aiohttp import web

from ipv8.keyvault.crypto import default_eccrypto
from ipv8.keyvault.private.libnaclkey import LibNaCLSK
from ipv8.util import succeed

import pytest

from tribler.core.components.knowledge.db.knowledge_db import KnowledgeDatabase
from tribler.core.components.libtorrent.download_manager.download import Download
from tribler.core.components.libtorrent.download_manager.download_config import DownloadConfig
from tribler.core.components.libtorrent.download_manager.download_manager import DownloadManager
from tribler.core.components.libtorrent.settings import LibtorrentSettings
from tribler.core.components.libtorrent.torrentdef import TorrentDef
from tribler.core.components.metadata_store.db.store import MetadataStore
from tribler.core.components.knowledge.db.knowledge_db import KnowledgeDatabase
from tribler.core.config.tribler_config import TriblerConfig
from tribler.core.tests.tools.common import TESTS_DATA_DIR, TESTS_DIR
from tribler.core.tests.tools.tracker.udp_tracker import UDPTracker
from tribler.core.utilities.network_utils import default_network_utils
from tribler.core.utilities.simpledefs import DLSTATUS_SEEDING
from tribler.core.utilities.unicode import hexlify


# Enable origin tracking for coroutine objects in the current thread, so when a test does not handle
# some coroutine properly, we can see a traceback with the name of the test which created the coroutine.
# Note that the error can happen in an unrelated test where the unhandled task from the previous test
Expand Down Expand Up @@ -234,12 +231,6 @@ def test_tdef(state_dir):
return tdef


@pytest.fixture
def event_loop():
# We use a SelectorEventLoop on all platforms so our test suite should use a similar event loop.
return asyncio.SelectorEventLoop()


@pytest.fixture
def loop(event_loop):
"""
Expand Down

0 comments on commit fcea30e

Please sign in to comment.