Skip to content

Commit ee1f316

Browse files
committed
fix: Unterminated format string
1 parent 6e844b9 commit ee1f316

File tree

1 file changed

+8
-11
lines changed

1 file changed

+8
-11
lines changed

tests/test_options.py

Lines changed: 8 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -44,14 +44,13 @@ def test_global_options_merged_with_provider_options():
4444
Testing a global option is used when no provider option is set.
4545
"""
4646
options.set_global_options(max_instances=66)
47-
pubsub_options = options.PubSubOptions(
48-
topic="foo") # pylint: disable=unexpected-keyword-arg
47+
pubsub_options = options.PubSubOptions(topic="foo") # pylint: disable=unexpected-keyword-arg
4948
pubsub_options_dict = pubsub_options._asdict_with_global_options()
5049
assert (pubsub_options_dict["topic"] == "foo"
51-
), "'topic' property missing from dict"
50+
), "'topic' property missing from dict"
5251
assert "options" not in pubsub_options_dict, "'options' key should not exist in dict"
5352
assert (pubsub_options_dict["max_instances"] == 66
54-
), "provider option did not update using the global option"
53+
), "provider option did not update using the global option"
5554

5655

5756
def test_https_options_removes_cors():
@@ -120,8 +119,7 @@ def test_merge_apis_empty_input():
120119
expected_output = []
121120
merged_apis = merge_required_apis(required_apis)
122121

123-
assert merged_apis == expected_output, f"Expected {
124-
expected_output}, but got {merged_apis}"
122+
assert merged_apis == expected_output, f"Expected {expected_output}, but got {merged_apis}"
125123

126124

127125
def test_merge_apis_no_duplicate_apis():
@@ -164,16 +162,15 @@ def test_merge_apis_no_duplicate_apis():
164162

165163
merged_apis = merge_required_apis(required_apis)
166164

167-
assert merged_apis == expected_output, f"Expected {
168-
expected_output}, but got {merged_apis}"
165+
assert merged_apis == expected_output, f"Expected {expected_output}, but got {merged_apis}"
169166

170167

171168
def test_merge_apis_duplicate_apis():
172169
"""
173170
This test evaluates the merge_required_apis function when the
174171
input list contains duplicate APIs with different reasons.
175172
The desired outcome for this test is a list where the duplicate
176-
APIs are merged properly and reasons are combined.
173+
APIs are merged properly and reasons are combined.
177174
This test ensures that the function correctly merges the duplicate
178175
APIs and combines the reasons associated with them.
179176
"""
@@ -215,11 +212,11 @@ def test_merge_apis_duplicate_apis():
215212

216213
for expected_item in expected_output:
217214
assert (expected_item in merged_apis
218-
), f"Expected item {expected_item} missing from the merged list"
215+
), f"Expected item {expected_item} missing from the merged list"
219216

220217
for actual_item in merged_apis:
221218
assert (actual_item in expected_output
222-
), f"Unexpected item {actual_item} found in the merged list"
219+
), f"Unexpected item {actual_item} found in the merged list"
223220

224221

225222
def test_invoker_with_one_element_doesnt_throw():

0 commit comments

Comments
 (0)