]> khamidou — GitHub mirrors - vcrpy.git/commitdiff
Fix/ignore some flake errors
authorJayson Reis <santosdosreis@gmail.com>
Wed, 20 Jan 2016 11:28:46 +0000 (12:28 +0100)
committerJayson Reis <santosdosreis@gmail.com>
Wed, 20 Jan 2016 11:28:46 +0000 (12:28 +0100)
tests/integration/test_boto.py
tests/integration/test_requests.py
tests/integration/test_wild.py
tests/unit/test_cassettes.py

index 84132d7a2dbdfe5cbeca6ea643b332dd5e7f0b19..6a396cc130a0854b182b6fefec5070e6a12f3891 100644 (file)
@@ -1,12 +1,12 @@
 import pytest
 boto = pytest.importorskip("boto")
 
-import boto
-import boto.iam
-from boto.s3.connection import S3Connection
-from boto.s3.key import Key
-from ConfigParser import DuplicateSectionError
-import vcr
+import boto  # NOQA
+import boto.iam  # NOQA
+from boto.s3.connection import S3Connection  # NOQA
+from boto.s3.key import Key  # NOQA
+from ConfigParser import DuplicateSectionError  # NOQA
+import vcr  # NOQA
 
 
 def test_boto_stubs(tmpdir):
index cc8360adeb54cfdf66e924d0f9a1d1c7cc2c2d9f..117e92e41f291c06ad56acc35ee639e7a1453077 100644 (file)
@@ -1,7 +1,5 @@
 # -*- coding: utf-8 -*-
 '''Test requests' interaction with vcr'''
-from io import BytesIO
-
 import pytest
 import vcr
 from assertions import assert_cassette_empty, assert_is_json
@@ -97,7 +95,7 @@ def test_post(tmpdir, scheme):
 
 
 def test_post_chunked_binary(tmpdir, scheme):
-    '''Ensure that we can send chunked binary without breaking while trying to concatenate bytes with string.'''
+    '''Ensure that we can send chunked binary without breaking while trying to concatenate bytes with str.'''
     data1 = iter([b'data', b'to', b'send'])
     data2 = iter([b'data', b'to', b'send'])
     url = scheme + '://httpbin.org/post'
index 47edc08f7b54e6e1b68d6fd788b64559e546538a..e8feeb5fc34f7eb245b68971b5fcb4562fb2b6be 100644 (file)
@@ -3,7 +3,7 @@ from six.moves import xmlrpc_client
 
 requests = pytest.importorskip("requests")
 
-import vcr
+import vcr  # NOQA
 
 try:
     import httplib
index fc7fac0251ed52bfeddc83f05f413f696e59a783..ef9e808c47392529fe2c7267e9d079aeb8d72f66 100644 (file)
@@ -233,7 +233,8 @@ def test_cassette_use_called_without_path_uses_function_to_generate_path():
 
 
 def test_path_transformer_with_function_path():
-    path_transformer = lambda path: os.path.join('a', path)
+    def path_transformer(path):
+        return os.path.join('a', path)
 
     @Cassette.use(inject=True, path_transformer=path_transformer)
     def function_name(cassette):