Skip to content

Commit fd954dd

Browse files
committed
chore: linting
1 parent 5b89215 commit fd954dd

File tree

2 files changed

+61
-43
lines changed

2 files changed

+61
-43
lines changed

tests/unit/core/test_parameters.py

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1787,7 +1787,7 @@ def test_needs_normalization_when_style_not_in_supported(
17871787
supported_parameter_styles={ParameterStyle.NUMERIC, ParameterStyle.NAMED_COLON},
17881788
)
17891789

1790-
needs_normalization = processor._needs_parse_normalization(param_info, config)
1790+
needs_normalization = processor._needs_parse_normalization(param_info, config) # pyright: ignore
17911791
assert needs_normalization is True
17921792

17931793
def test_no_normalization_when_style_in_supported(
@@ -1803,7 +1803,7 @@ def test_no_normalization_when_style_in_supported(
18031803
supported_parameter_styles={ParameterStyle.NUMERIC, ParameterStyle.NAMED_COLON},
18041804
)
18051805

1806-
needs_normalization = processor._needs_parse_normalization(param_info, config)
1806+
needs_normalization = processor._needs_parse_normalization(param_info, config) # pyright: ignore
18071807
assert needs_normalization is False
18081808

18091809
def test_normalization_converts_to_default_style(
@@ -1818,7 +1818,7 @@ def test_normalization_converts_to_default_style(
18181818
supported_parameter_styles={ParameterStyle.NUMERIC, ParameterStyle.NAMED_COLON},
18191819
)
18201820

1821-
normalized_sql = processor._normalize_sql_for_parsing(sql, param_info, config)
1821+
normalized_sql = processor._normalize_sql_for_parsing(sql, param_info, config) # pyright: ignore
18221822

18231823
# Should have converted to NUMERIC ($1)
18241824
assert "%(name)s" not in normalized_sql
@@ -1836,7 +1836,7 @@ def test_no_normalization_preserves_original_sql(
18361836
supported_parameter_styles={ParameterStyle.NUMERIC, ParameterStyle.NAMED_COLON},
18371837
)
18381838

1839-
normalized_sql = processor._normalize_sql_for_parsing(sql, param_info, config)
1839+
normalized_sql = processor._normalize_sql_for_parsing(sql, param_info, config) # pyright: ignore
18401840
assert normalized_sql == sql
18411841

18421842
def test_none_supported_styles_defaults_to_default_style(
@@ -1855,12 +1855,12 @@ def test_none_supported_styles_defaults_to_default_style(
18551855
# SQL with NUMERIC should NOT need normalization
18561856
sql_numeric = "SELECT * FROM t WHERE id = $1"
18571857
param_info_numeric = validator.extract_parameters(sql_numeric)
1858-
assert processor._needs_parse_normalization(param_info_numeric, config) is False
1858+
assert processor._needs_parse_normalization(param_info_numeric, config) is False # pyright: ignore
18591859

18601860
# SQL with NAMED_PYFORMAT SHOULD need normalization (not in default set)
18611861
sql_pyformat = "SELECT * FROM t WHERE id = %(name)s"
18621862
param_info_pyformat = validator.extract_parameters(sql_pyformat)
1863-
assert processor._needs_parse_normalization(param_info_pyformat, config) is True
1863+
assert processor._needs_parse_normalization(param_info_pyformat, config) is True # pyright: ignore
18641864

18651865
def test_multiple_unsupported_parameters_all_normalized(
18661866
self, processor: ParameterProcessor, validator: ParameterValidator
@@ -1873,7 +1873,7 @@ def test_multiple_unsupported_parameters_all_normalized(
18731873
default_parameter_style=ParameterStyle.NUMERIC, supported_parameter_styles={ParameterStyle.NUMERIC}
18741874
)
18751875

1876-
normalized_sql = processor._normalize_sql_for_parsing(sql, param_info, config)
1876+
normalized_sql = processor._normalize_sql_for_parsing(sql, param_info, config) # pyright: ignore
18771877

18781878
# No pyformat placeholders should remain
18791879
assert "%(a)s" not in normalized_sql

0 commit comments

Comments
 (0)