E402 Module level import not at top of file
MODIFY
test/benchmark.py
test/benchmark.py
@@ -11,7 +11,7 @@ import time
import urllib
sys.path.append('../')
-import urllib3
+import urllib3 # noqa: E402
# URLs to download. Doesn't matter as long as they're from the same host, so we

MODIFY
test/test_collections.py
test/test_collections.py
@@ -4,11 +4,11 @@ from urllib3._collections import (
HTTPHeaderDict,
RecentlyUsedContainer as Container
)
+from nose.plugins.skip import SkipTest
+
from urllib3.packages import six
xrange = six.moves.xrange
-from nose.plugins.skip import SkipTest
-
class TestLRUContainer(unittest.TestCase):
def test_maxsize(self):

MODIFY
test/test_connection.py
test/test_connection.py
import datetime
-import sys
-if sys.version_info >= (2, 7):
- import unittest
-else:
- import unittest2 as unittest
-
import mock
+import sys
from urllib3.connection import (
CertificateError,
@@ -13,6 +8,11 @@ from urllib3.connection import (
RECENT_DATE
)
+if sys.version_info >= (2, 7):
+ import unittest
+else:
+ import unittest2 as unittest
+
class TestConnection(unittest.TestCase):
"""

E402 Module level import not at top of file