pre-commit run reorder-python-imports --all-files

This commit is contained in:
Anthony Sottile 2019-06-02 15:31:29 -07:00 committed by Bruno Oliveira
parent 5034399d7a
commit 3f1ec520fc
80 changed files with 3 additions and 312 deletions

View File

@ -1,5 +1,3 @@
from six.moves import range
import pytest
SKIP = True

View File

@ -53,10 +53,6 @@ If things do not work right away:
which should throw a KeyError: 'COMPLINE' (which is properly set by the
global argcomplete script).
"""
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import os
import sys
from glob import glob

View File

@ -1,8 +1,4 @@
""" python inspection/code generation API """
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
from .code import Code # noqa
from .code import ExceptionInfo # noqa
from .code import filter_traceback # noqa

View File

@ -2,11 +2,6 @@
# CHANGES:
# - some_str is replaced, trying to create unicode strings
#
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
from __future__ import unicode_literals
import types
from six import text_type

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import inspect
import re
import sys

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import ast
import inspect
import linecache

View File

@ -1,6 +1,5 @@
import pprint
from six.moves import reprlib
import reprlib
def _call_and_format_exception(call, x, *args):

View File

@ -1,10 +1,6 @@
"""
support for presenting detailed information in failing assertions.
"""
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import sys
import six

View File

@ -1,8 +1,4 @@
"""Rewrite assertion AST to produce nice error messages"""
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import ast
import errno
import imp

View File

@ -4,10 +4,6 @@ Utilities for truncating assertion output.
Current default behaviour is to truncate assertion explanations at
~8 terminal lines, unless running in "-vv" mode or running on CI.
"""
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import os
import six

View File

@ -1,8 +1,4 @@
"""Utilities for assertion debugging"""
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import pprint
from collections.abc import Sequence

View File

@ -4,10 +4,6 @@ merged implementation of the cache provider
the name cache was not chosen to ensure pluggy automatically
ignores the external pytest-cache
"""
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import json
import os
from collections import OrderedDict

View File

@ -2,10 +2,6 @@
per-test stdout/stderr capturing mechanism.
"""
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import collections
import contextlib
import io

View File

@ -1,10 +1,6 @@
"""
python version compatibility code
"""
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import functools
import inspect
import io

View File

@ -1,8 +1,4 @@
""" command line options, ini-file and conftest.py processing. """
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import argparse
import copy
import inspect

View File

@ -1,8 +1,4 @@
""" interactive debugging with PDB, the Python Debugger. """
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import argparse
import pdb
import sys

View File

@ -8,10 +8,6 @@ be removed when the time comes.
All constants defined in this module should be either PytestWarning instances or UnformattedWarning
in case of warnings which need to format their messages.
"""
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
from _pytest.warning_types import PytestDeprecationWarning
from _pytest.warning_types import RemovedInPytest4Warning
from _pytest.warning_types import UnformattedWarning

View File

@ -1,8 +1,4 @@
""" discover and run doctests in modules and test files."""
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import inspect
import platform
import sys

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import functools
import inspect
import itertools

View File

@ -2,9 +2,6 @@
Provides a function to report all internal modules for using freezing tools
pytest
"""
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
def freeze_includes():

View File

@ -1,8 +1,4 @@
""" version info, help messages, tracing configuration. """
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import os
import sys
from argparse import Action

View File

@ -8,10 +8,6 @@ Based on initial code from Ross Lawley.
Output conforms to https://github.com/jenkinsci/xunit-plugin/blob/master/
src/main/resources/org/jenkinsci/plugins/xunit/types/model/xsd/junit-10.xsd
"""
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import functools
import os
import re

View File

@ -1,8 +1,4 @@
""" Access and control log capturing. """
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import logging
import re
from contextlib import contextmanager

View File

@ -1,8 +1,4 @@
""" core implementation of testing process: init, session, runtest loop. """
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import fnmatch
import functools
import os

View File

@ -1,8 +1,4 @@
""" generic mechanism for marking and selecting python functions. """
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
from .legacy import matchkeyword
from .legacy import matchmark
from .structures import EMPTY_PARAMETERSET_OPTION

View File

@ -1,8 +1,4 @@
""" monkeypatching and mocking functionality. """
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import os
import re
import sys

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import os
import warnings

View File

@ -1,8 +1,4 @@
""" run test suites written for nose. """
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import sys
import six

View File

@ -2,10 +2,6 @@
exception classes and constants handling test outcomes
as well as functions creating them
"""
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import sys
from packaging.version import Version

View File

@ -1,8 +1,4 @@
""" submit failure or test session information to a pastebin service. """
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import tempfile
import six

View File

@ -14,7 +14,6 @@ from os.path import sep
from posixpath import sep as posix_sep
import six
from six.moves import map
if sys.version_info[:2] >= (3, 6):

View File

@ -1,8 +1,4 @@
"""(disabled by default) support for testing pytest and pytest plugins."""
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import codecs
import gc
import os

View File

@ -1,8 +1,4 @@
""" Python test discovery, setup and run of test functions. """
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import collections
import enum
import fnmatch

View File

@ -1,5 +1,3 @@
from __future__ import absolute_import
import math
import pprint
import sys
@ -8,11 +6,10 @@ from collections.abc import Iterable
from collections.abc import Mapping
from collections.abc import Sized
from decimal import Decimal
from itertools import filterfalse
from numbers import Number
from more_itertools.more import always_iterable
from six.moves import filterfalse
from six.moves import zip
import _pytest._code
from _pytest import deprecated

View File

@ -1,8 +1,4 @@
""" recording warnings during test function execution. """
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import inspect
import re
import sys

View File

@ -1,10 +1,6 @@
""" log machine-parseable test session result information in a plain
text file.
"""
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import os
import py

View File

@ -1,8 +1,4 @@
""" basic collect and runtest protocol implementations """
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import bdb
import os
import sys

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import sys
import pytest

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import pytest

View File

@ -1,8 +1,4 @@
""" support for skip/xfail functions and markers. """
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
from _pytest.config import hookimpl
from _pytest.mark.evaluate import MarkEvaluator
from _pytest.outcomes import fail

View File

@ -2,10 +2,6 @@
This is a good source for looking at the various reporting hooks.
"""
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import argparse
import collections
import platform

View File

@ -1,8 +1,4 @@
""" support for providing temporary directories to test functions. """
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import os
import re
import tempfile

View File

@ -1,8 +1,4 @@
""" discovery and running of std-library "unittest" style tests. """
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import sys
import traceback

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import sys
import warnings
from contextlib import contextmanager

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import os
import sys
import textwrap

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import sys
from unittest import mock

View File

@ -1,15 +1,11 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import operator
import os
import queue
import sys
import textwrap
import py
import six
from six.moves import queue
import _pytest
import pytest

View File

@ -1,10 +1,6 @@
# flake8: noqa
# disable flake check on this file because some constructs are strange
# or redundant on purpose and can't be disable on a line-by-line basis
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import ast
import inspect
import sys

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import os
import pytest

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import subprocess
import sys

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import collections.abc as collections_abc
import sys
import textwrap

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import ast
import glob
import os

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import os
import shutil
import sys

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import contextlib
import io
import os

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import os
import pprint
import sys

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import sys
from functools import wraps

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import sys
import textwrap

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import textwrap
import py

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import textwrap
import pytest

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import importlib_metadata

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import pytest
from _pytest.main import EXIT_NOTESTSCOLLECTED

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import os
from xml.dom import minidom

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import os
import sys
from unittest import mock

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import os
import re
import sys

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import pytest

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import argparse
import distutils.spawn
import os

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import pytest

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import os
import sys

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import os
import sys
import types

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import os
import subprocess
import sys

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import re
import warnings

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import os
import py

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import inspect
import os
import sys

View File

@ -2,10 +2,6 @@
test correct setup/teardowns at
module, class, and instance level
"""
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import pytest

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import pytest
from _pytest.main import EXIT_NOTESTSCOLLECTED

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import sys
import pytest

View File

@ -1,10 +1,6 @@
"""
terminal reporting of the full testing process.
"""
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import collections
import os
import sys

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import sys
import attr

View File

@ -1,7 +1,3 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import gc
import pytest

View File

@ -1,5 +1,3 @@
from __future__ import unicode_literals
import warnings
import pytest