Fixed warning and broken tests on 3.3

This commit is contained in:
Armin Ronacher 2014-02-08 22:29:46 +00:00
parent e67d9a04b2
commit d094d5b6fc
2 changed files with 5 additions and 4 deletions

View file

@ -265,8 +265,9 @@ class SendfileTestCase(FlaskTestCase):
# etags
self.assert_equal(len(captured), 1)
with catch_warnings() as captured:
from StringIO import StringIO as PYStringIO
f = PYStringIO('Test')
class PyStringIO(StringIO):
pass
f = PyStringIO('Test')
f.name = 'test.txt'
rv = flask.send_file(f)
rv.direct_passthrough = False

View file

@ -207,8 +207,8 @@ class TestToolsTestCase(FlaskTestCase):
with app.test_client() as c:
rv = c.post('http://domain.com/action?vodka=42', data={'gin': 43})
self.assert_equal(rv.status_code, 200)
self.assert_('gin' in flask.request.form)
self.assert_('vodka' in flask.request.args)
self.assert_true('gin' in flask.request.form)
self.assert_true('vodka' in flask.request.args)
class SubdomainTestCase(FlaskTestCase):