fixup: remove remove unused alias in code
This commit is contained in:
@@ -1,6 +1,8 @@
|
||||
# mypy: allow-untyped-defs
|
||||
"""Reproduces issue #3774"""
|
||||
|
||||
from __future__ import annotations
|
||||
|
||||
from unittest import mock
|
||||
|
||||
import pytest
|
||||
|
||||
@@ -1,3 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
|
||||
def test_init():
|
||||
pass
|
||||
|
||||
@@ -1,3 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
|
||||
def test_foo():
|
||||
pass
|
||||
|
||||
@@ -1,3 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
|
||||
def pytest_ignore_collect(collection_path):
|
||||
return False
|
||||
|
||||
@@ -1,3 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
|
||||
def test():
|
||||
pass
|
||||
|
||||
@@ -1,3 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
|
||||
def test_init():
|
||||
pass
|
||||
|
||||
@@ -1,3 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
|
||||
def test_foo():
|
||||
pass
|
||||
|
||||
@@ -1,2 +1,5 @@
|
||||
from __future__ import annotations
|
||||
|
||||
|
||||
class pytest_something:
|
||||
pass
|
||||
|
||||
@@ -1,3 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
|
||||
def test_foo():
|
||||
pass
|
||||
|
||||
@@ -1,4 +1,7 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
|
||||
def pytest_configure(config):
|
||||
import pytest
|
||||
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
# mypy: allow-untyped-defs
|
||||
# content of conftest.py
|
||||
from __future__ import annotations
|
||||
|
||||
import json
|
||||
|
||||
import pytest
|
||||
|
||||
@@ -1,4 +1,7 @@
|
||||
# mypy: allow-untyped-defs
|
||||
# content of test_first.py
|
||||
from __future__ import annotations
|
||||
|
||||
|
||||
def test_1():
|
||||
pass
|
||||
|
||||
@@ -1,4 +1,7 @@
|
||||
# mypy: allow-untyped-defs
|
||||
# content of test_second.py
|
||||
from __future__ import annotations
|
||||
|
||||
|
||||
def test_2():
|
||||
pass
|
||||
|
||||
@@ -1,4 +1,7 @@
|
||||
# mypy: allow-untyped-defs
|
||||
# content of test_third.py
|
||||
from __future__ import annotations
|
||||
|
||||
|
||||
def test_3():
|
||||
pass
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
from __future__ import annotations
|
||||
|
||||
from dataclasses import dataclass
|
||||
from dataclasses import field
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
from __future__ import annotations
|
||||
|
||||
from dataclasses import dataclass
|
||||
from dataclasses import field
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
from __future__ import annotations
|
||||
|
||||
from dataclasses import dataclass
|
||||
from dataclasses import field
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
from __future__ import annotations
|
||||
|
||||
from dataclasses import dataclass
|
||||
from dataclasses import field
|
||||
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
from dataclasses import dataclass
|
||||
from dataclasses import InitVar
|
||||
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
from dataclasses import dataclass
|
||||
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
from __future__ import annotations
|
||||
|
||||
from dataclasses import dataclass
|
||||
from dataclasses import field
|
||||
|
||||
|
||||
@@ -1,3 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
|
||||
def test_this_is_ignored():
|
||||
assert True
|
||||
|
||||
@@ -1,4 +1,7 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
|
||||
def test_doc():
|
||||
"""
|
||||
>>> 10 > 5
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
import pytest
|
||||
|
||||
|
||||
|
||||
@@ -1,3 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
|
||||
def test():
|
||||
pass
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
import pytest
|
||||
|
||||
|
||||
|
||||
@@ -1,3 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
|
||||
def test_1(arg1):
|
||||
pass
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
import pytest
|
||||
|
||||
|
||||
|
||||
@@ -1,3 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
|
||||
def test_2(arg2):
|
||||
pass
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
import pytest
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
import pytest
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
import pytest
|
||||
|
||||
|
||||
|
||||
@@ -1,3 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
|
||||
def test_spam(spam):
|
||||
assert spam == "spamspam"
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
import pytest
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
import pytest
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
import pytest
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
import pytest
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
import pytest
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
import pytest
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
import pytest
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
import pytest
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
import pytest
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
import pytest
|
||||
|
||||
|
||||
|
||||
@@ -1,3 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
|
||||
def test_hello():
|
||||
pass
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
import pprint
|
||||
from typing import List
|
||||
from typing import Tuple
|
||||
|
||||
import pytest
|
||||
|
||||
@@ -16,7 +16,7 @@ def pytest_generate_tests(metafunc):
|
||||
|
||||
@pytest.fixture(scope="session")
|
||||
def checked_order():
|
||||
order: List[Tuple[str, str, str]] = []
|
||||
order: list[tuple[str, str, str]] = []
|
||||
|
||||
yield order
|
||||
pprint.pprint(order)
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
import pytest
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
import argparse
|
||||
import pathlib
|
||||
|
||||
|
||||
@@ -1,3 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
|
||||
def test_x():
|
||||
pass
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
import pytest
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
import unittest
|
||||
|
||||
import pytest
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
# mypy: allow-untyped-defs
|
||||
"""Skipping an entire subclass with unittest.skip() should *not* call setUp from a base class."""
|
||||
|
||||
from __future__ import annotations
|
||||
|
||||
import unittest
|
||||
|
||||
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
# mypy: allow-untyped-defs
|
||||
"""Skipping an entire subclass with unittest.skip() should *not* call setUpClass from a base class."""
|
||||
|
||||
from __future__ import annotations
|
||||
|
||||
import unittest
|
||||
|
||||
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
# mypy: allow-untyped-defs
|
||||
"""setUpModule is always called, even if all tests in the module are skipped"""
|
||||
|
||||
from __future__ import annotations
|
||||
|
||||
import unittest
|
||||
|
||||
|
||||
|
||||
@@ -1,9 +1,10 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from typing import List
|
||||
from __future__ import annotations
|
||||
|
||||
from unittest import IsolatedAsyncioTestCase
|
||||
|
||||
|
||||
teardowns: List[None] = []
|
||||
teardowns: list[None] = []
|
||||
|
||||
|
||||
class AsyncArguments(IsolatedAsyncioTestCase):
|
||||
|
||||
@@ -1,13 +1,14 @@
|
||||
# mypy: allow-untyped-defs
|
||||
"""Issue #7110"""
|
||||
|
||||
from __future__ import annotations
|
||||
|
||||
import asyncio
|
||||
from typing import List
|
||||
|
||||
import asynctest
|
||||
|
||||
|
||||
teardowns: List[None] = []
|
||||
teardowns: list[None] = []
|
||||
|
||||
|
||||
class Test(asynctest.TestCase):
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
import unittest
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
import warnings
|
||||
|
||||
import pytest
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
import warnings
|
||||
|
||||
import pytest
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
# mypy: allow-untyped-defs
|
||||
from __future__ import annotations
|
||||
|
||||
from test_1 import func
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user