Reformat with black

https://github.com/python/black
This commit is contained in:
David Baumgold 2019-05-06 15:39:41 -04:00
parent 5b309831ec
commit 025589ee76
63 changed files with 3784 additions and 3459 deletions

View file

@ -3,12 +3,15 @@ import pytest
from flask import template_rendered
@pytest.mark.parametrize(('path', 'template_name'), (
('/', 'plain.html'),
('/plain', 'plain.html'),
('/fetch', 'fetch.html'),
('/jquery', 'jquery.html'),
))
@pytest.mark.parametrize(
("path", "template_name"),
(
("/", "plain.html"),
("/plain", "plain.html"),
("/fetch", "fetch.html"),
("/jquery", "jquery.html"),
),
)
def test_index(app, client, path, template_name):
def check(sender, template, context):
assert template.name == template_name
@ -17,12 +20,9 @@ def test_index(app, client, path, template_name):
client.get(path)
@pytest.mark.parametrize(('a', 'b', 'result'), (
(2, 3, 5),
(2.5, 3, 5.5),
(2, None, 2),
(2, 'b', 2),
))
@pytest.mark.parametrize(
("a", "b", "result"), ((2, 3, 5), (2.5, 3, 5.5), (2, None, 2), (2, "b", 2))
)
def test_add(client, a, b, result):
response = client.post('/add', data={'a': a, 'b': b})
assert response.get_json()['result'] == result
response = client.post("/add", data={"a": a, "b": b})
assert response.get_json()["result"] == result