Lines Matching refs:fileobj
147 f = gzip.GzipFile(fileobj=io.BytesIO(compressed), mode='rb')
157 fileobj = f.fileobj
158 self.assertFalse(fileobj.closed)
160 self.assertTrue(fileobj.closed)
169 fileobj = f.fileobj
170 self.assertFalse(fileobj.closed)
172 self.assertTrue(fileobj.closed)
303 self.assertTrue(hasattr(f.fileobj, "name"))
304 self.assertEqual(f.fileobj.name, self.filename)
437 with gzip.GzipFile(fileobj=buf, mode="wb") as f:
441 with gzip.GzipFile(fileobj=buf, mode="rb") as f:
476 # fileobj created with os.fdopen().
479 with gzip.GzipFile(fileobj=f, mode="w") as g:
485 with gzip.GzipFile(fileobj=f, mode='r') as g:
487 with gzip.GzipFile(fileobj=f, mode='w') as g:
489 with gzip.GzipFile(fileobj=f, mode='a') as g:
491 with gzip.GzipFile(fileobj=f, mode='x') as g:
494 gzip.GzipFile(fileobj=f, mode='z')
497 with gzip.GzipFile(fileobj=f) as g:
504 g = gzip.GzipFile(fileobj=f)
528 decomp = gzip.GzipFile(fileobj=bomb)
541 with gzip.GzipFile(fileobj=io.BytesIO(datac), mode="rb") as f:
551 with gzip.GzipFile(fileobj=io.BytesIO(datac), mode="rb") as f:
567 with gzip.GzipFile(fileobj=buf, mode="wb") as f:
586 with gzip.GzipFile(fileobj=io.BytesIO(truncated)) as f:
588 with gzip.GzipFile(fileobj=io.BytesIO(truncated)) as f:
593 with gzip.GzipFile(fileobj=io.BytesIO(truncated[:i])) as f:
601 with gzip.GzipFile(fileobj=io.BytesIO(gzdata)) as f:
615 with gzip.GzipFile(fileobj=io.BytesIO(), mode='w') as f:
775 with gzip.GzipFile(fileobj=bytes_io, mode='wb') as gzip_file: