Skip to content

Commit 3aaa84a

Browse files
committed
noqa rules updates per ruff checks
1 parent ca5376d commit 3aaa84a

File tree

5 files changed

+6
-6
lines changed

5 files changed

+6
-6
lines changed

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ max-doc-length = 88
7777

7878
# Disable docstring checking for these directories
7979
[tool.ruff.lint.per-file-ignores]
80-
"python/tests/*" = ["ANN", "ARG", "D", "S101", "SLF", "PD"]
80+
"python/tests/*" = ["ANN", "ARG", "D", "S101", "SLF", "PD", "PLR2004", "RUF015"]
8181
"examples/*" = ["D", "W505"]
8282
"dev/*" = ["D"]
8383
"benchmarks/*" = ["D", "F"]

python/tests/test_aggregation.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -299,7 +299,7 @@ def test_aggregate_100(df_aggregate_100, name, expr, expected):
299299
]
300300

301301

302-
@pytest.mark.parametrize("name,expr,result", data_test_bitwise_and_boolean_functions)
302+
@pytest.mark.parametrize(("name","expr","result"), data_test_bitwise_and_boolean_functions)
303303
def test_bit_and_bool_fns(df, name, expr, result):
304304
df = df.aggregate([], [expr.alias(name)])
305305

python/tests/test_imports.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -169,14 +169,14 @@ def test_class_module_is_datafusion():
169169

170170

171171
def test_import_from_functions_submodule():
172-
from datafusion.functions import abs, sin # noqa
172+
from datafusion.functions import abs, sin # noqa: A004
173173

174174
assert functions.abs is abs
175175
assert functions.sin is sin
176176

177177
msg = "cannot import name 'foobar' from 'datafusion.functions'"
178178
with pytest.raises(ImportError, match=msg):
179-
from datafusion.functions import foobar # noqa
179+
from datafusion.functions import foobar # noqa: F401
180180

181181

182182
def test_classes_are_inheritable():

python/tests/test_udaf.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ def test_errors(df):
8686
"evaluate, merge, update)"
8787
)
8888
with pytest.raises(Exception, match=msg):
89-
accum = udaf( # noqa F841
89+
accum = udaf( # noqa: F841
9090
MissingMethods,
9191
pa.int64(),
9292
pa.int64(),

python/tests/test_udwf.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -298,7 +298,7 @@ def test_udwf_errors(df):
298298
]
299299

300300

301-
@pytest.mark.parametrize("name,expr,expected", data_test_udwf_functions)
301+
@pytest.mark.parametrize(("name","expr","expected"), data_test_udwf_functions)
302302
def test_udwf_functions(df, name, expr, expected):
303303
df = df.select("a", "b", f.round(expr, lit(3)).alias(name))
304304

0 commit comments

Comments
 (0)