Skip to content

Commit 2364304

Browse files
committed
🐍 Reformatted with black Closes faif#375
1 parent 24c6cc8 commit 2364304

File tree

3 files changed

+7
-18
lines changed

3 files changed

+7
-18
lines changed

tests/behavioral/test_publish_subscribe.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ def test_subscriber_shall_be_detachable_from_subscriptions(cls):
2727
cls.assertEqual(len(pro.subscribers[subscription]), 0)
2828

2929
def test_publisher_shall_append_subscription_message_to_queue(cls):
30-
""" msg_queue ~ Provider.notify(msg) ~ Publisher.publish(msg) """
30+
"""msg_queue ~ Provider.notify(msg) ~ Publisher.publish(msg)"""
3131
expected_msg = "expected msg"
3232
pro = Provider()
3333
pub = Publisher(pro)

tests/behavioral/test_strategy.py

Lines changed: 3 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -9,22 +9,14 @@ def order():
99

1010

1111
@pytest.mark.parametrize(
12-
"func, discount",
13-
[
14-
(ten_percent_discount, 10.0),
15-
(on_sale_discount, 45.0)
16-
]
12+
"func, discount", [(ten_percent_discount, 10.0), (on_sale_discount, 45.0)]
1713
)
1814
def test_discount_function_return(func, order, discount):
1915
assert func(order) == discount
2016

2117

2218
@pytest.mark.parametrize(
23-
"func, price",
24-
[
25-
(ten_percent_discount, 100),
26-
(on_sale_discount, 100)
27-
]
19+
"func, price", [(ten_percent_discount, 100), (on_sale_discount, 100)]
2820
)
2921
def test_order_discount_strategy_validate_success(func, price):
3022
order = Order(price, func)
@@ -41,10 +33,7 @@ def test_order_discount_strategy_validate_error():
4133

4234
@pytest.mark.parametrize(
4335
"func, price, discount",
44-
[
45-
(ten_percent_discount, 100, 90.0),
46-
(on_sale_discount, 100, 55.0)
47-
]
36+
[(ten_percent_discount, 100, 90.0), (on_sale_discount, 100, 55.0)],
4837
)
4938
def test_discount_apply_success(func, price, discount):
5039
order = Order(price, func)

tests/structural/test_proxy.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,17 +8,17 @@
88
class ProxyTest(unittest.TestCase):
99
@classmethod
1010
def setUpClass(cls):
11-
""" Class scope setup. """
11+
"""Class scope setup."""
1212
cls.proxy = Proxy()
1313

1414
def setUp(cls):
15-
""" Function/test case scope setup. """
15+
"""Function/test case scope setup."""
1616
cls.output = StringIO()
1717
cls.saved_stdout = sys.stdout
1818
sys.stdout = cls.output
1919

2020
def tearDown(cls):
21-
""" Function/test case scope teardown. """
21+
"""Function/test case scope teardown."""
2222
cls.output.close()
2323
sys.stdout = cls.saved_stdout
2424

0 commit comments

Comments
 (0)