File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -214,10 +214,10 @@ def _prepare_batch_request(self):
214
214
timeout = _timeout
215
215
216
216
# The `email` package expects to deal with "native" strings
217
- if six .PY3 : # pragma: NO COVER Python3
218
- buf = io .StringIO ()
219
- else :
217
+ if six .PY2 : # pragma: NO COVER Python3
220
218
buf = io .BytesIO ()
219
+ else :
220
+ buf = io .StringIO ()
221
221
generator = Generator (buf , False , 0 )
222
222
generator .flatten (multi )
223
223
payload = buf .getvalue ()
Original file line number Diff line number Diff line change @@ -69,8 +69,8 @@ def test_w_expiration_int(self):
69
69
self .assertEqual (self ._call_fut (123 ), 123 )
70
70
71
71
def test_w_expiration_long (self ):
72
- if six .PY3 :
73
- raise unittest .SkipTest ("No long on Python 3" )
72
+ if not six .PY2 :
73
+ raise unittest .SkipTest ("No long on Python 3+ " )
74
74
75
75
self .assertEqual (self ._call_fut (long (123 )), 123 ) # noqa: F821
76
76
You can’t perform that action at this time.
0 commit comments