Skip to content

Commit c7a7653

Browse files
committed
Appease flake8 in pattern matching test
1 parent d4a805f commit c7a7653

1 file changed

Lines changed: 5 additions & 5 deletions

File tree

test/splitgraph/commands/test_es_fdw_queries.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ def test_pattern_matching_queries(local_engine_empty):
4848
"must": [
4949
{
5050
"wildcard": {
51-
r"firstname": "any: *; percent: %; backslash-and-any: \\*; backslash-and-percent: \\%"
51+
"firstname": r"any: *; percent: %; backslash-and-any: \*; backslash-and-percent: \%"
5252
}
5353
}
5454
]
@@ -70,7 +70,7 @@ def test_pattern_matching_queries(local_engine_empty):
7070
"must": [
7171
{
7272
"wildcard": {
73-
r"firstname": "single-char: ?; underscore: _; backslash-and-single-char: \\?; backslash-and-underscore: \\_"
73+
"firstname": r"single-char: ?; underscore: _; backslash-and-single-char: \?; backslash-and-underscore: \_"
7474
}
7575
}
7676
]
@@ -93,7 +93,7 @@ def test_pattern_matching_queries(local_engine_empty):
9393
"must": [
9494
{
9595
"wildcard": {
96-
r"firstname": "star: \*; question-mark: \?; multiple-stars-and-question-marks: \*\*\*\*\?\?"
96+
"firstname": r"star: \*; question-mark: \?; multiple-stars-and-question-marks: \*\*\*\*\?\?"
9797
}
9898
}
9999
]
@@ -113,7 +113,7 @@ def test_pattern_matching_queries(local_engine_empty):
113113
# Ensure results are correct
114114
result = local_engine_empty.run_sql(query, return_shape=ResultShape.MANY_ONE)
115115
assert len(result) == 4
116-
assert set(result) == set(["Susan", "Susana", "Susanne", "Suzanne"])
116+
assert set(result) == {"Susan", "Susana", "Susanne", "Suzanne"}
117117

118118
# Test meaningful pattern match query returns correct result
119119
query = "SELECT firstname FROM es.account WHERE firstname !~~ 'Su_an%'"
@@ -127,7 +127,7 @@ def test_pattern_matching_queries(local_engine_empty):
127127
# Ensure results are correct
128128
result = local_engine_empty.run_sql(query, return_shape=ResultShape.MANY_ONE)
129129
assert len(result) == 996
130-
assert not set(["Susan", "Susana", "Susanne", "Suzanne"]).issubset(set(result))
130+
assert not {"Susan", "Susana", "Susanne", "Suzanne"}.issubset(set(result))
131131

132132

133133
@pytest.mark.mounting

0 commit comments

Comments
 (0)