Commit 5ce3db7e authored by jvoisin's avatar jvoisin

Bump coverage

parent c289edb9
Pipeline #21598 passed with stages
in 1 minute and 17 seconds
......@@ -70,5 +70,5 @@ def upload_file():
return render_template('index.html', mimetypes=mimetypes)
if __name__ == '__main__':
if __name__ == '__main__': # pragma: no cover
app.run()
......@@ -47,6 +47,15 @@ class FlaskrTestCase(unittest.TestCase):
rv.data)
self.assertEqual(rv.status_code, 200)
def test_get_upload_no_file_name(self):
rv = self.app.post('/',
data=dict(
file=(io.BytesIO(b"aaa"), ''),
), follow_redirects=True)
self.assertIn(b'No file part', rv.data)
self.assertEqual(rv.status_code, 200)
def test_get_upload_harmless_file(self):
rv = self.app.post('/',
data=dict(
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment