]> khamidou — GitHub mirrors - vcrpy.git/commitdiff
Updated comments
authorNick DiRienzo <nicholas.dirienzo@optimizely.com>
Tue, 21 Jun 2016 06:43:47 +0000 (23:43 -0700)
committerNick DiRienzo <nicholas.dirienzo@optimizely.com>
Tue, 21 Jun 2016 06:43:47 +0000 (23:43 -0700)
tests/integration/test_stubs.py
vcr/filters.py

index 79c6c357dcd8c7fa1031d0a7073687e07d74748a..92ce0f244de8c0c63e0a35f302a6f21bbf891110 100644 (file)
@@ -66,8 +66,8 @@ def test_original_decoded_response_is_not_modified(tmpdir, httpbin):
         assert inside.headers.items() == outside.headers.items()
         assert inside.read() == outside.read()
 
-    # Even though the above are raw bytes, the JSON data should have be decoded
-    # and saved to the cassette.
+    # Even though the above are raw bytes, the JSON data should have been
+    # decoded and saved to the cassette.
     with vcr.use_cassette(testfile) as cass:
         inside2 = urlopen(request)
         assert 'content-encoding' not in inside2.headers
index d1a3037dde0ee21bdf0de141202b5b52f4a5fce7..bd7e6c65188560ab6843fbbcfe1d03b650267a28 100644 (file)
@@ -146,8 +146,8 @@ def decode_response(response):
         else:  # encoding == 'deflate'
             return zlib.decompress(body)
 
-    # Deepcopy here in case headers contain lists and other objects that could
-    # be mutated by a shallow copy.
+    # Deepcopy here in case `headers` contain objects that could
+    # be mutated by a shallow copy and corrupt the real response.
     response = copy.deepcopy(response)
     headers = CaseInsensitiveDict(response['headers'])
     if is_compressed(headers):