Hack around text problem in unit tests.

Now that payloads are not allowed to be text, some unit tests will cause crashes
on Python 3 because the payload sent by requests gets passed to FakeKey as a
string instead of raw bytes.

I haven't been able to figure out a way around the issue that doesn't get super
messy inside s3/responses.py so I'm just converting the value to bytes using the
system's default encoding.
This commit is contained in:
Diego Argueta 2018-12-20 00:34:04 -08:00
commit f15f006f78
2 changed files with 11 additions and 0 deletions

View file

@ -2,6 +2,10 @@
envlist = py27, py36
[testenv]
setenv =
BOTO_CONFIG=/dev/null
AWS_SECRET_ACCESS_KEY=foobar_secret
AWS_ACCESS_KEY_ID=foobar_key
deps =
-r{toxinidir}/requirements.txt
-r{toxinidir}/requirements-dev.txt