Skip to content

Commit

Permalink
Add unnecessary-lambda check (#3892)
Browse files Browse the repository at this point in the history
  • Loading branch information
Ruchip16 authored Apr 24, 2023
1 parent 354cda0 commit 913f474
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
1 change: 0 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,6 @@ disable = [
"too-many-public-methods",
"unidiomatic-typecheck",
"unnecessary-comprehension",
"unnecessary-lambda",
# Next rule was added because we cannot adjust the open calls during minor
# releases since there is no guarantee that this will not break existing
# scenarios (right now, we have no idea what encoding files that molecule
Expand Down
7 changes: 5 additions & 2 deletions src/molecule/test/unit/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
# DEALINGS IN THE SOFTWARE.

import copy
import functools
import os
import shutil
from collections.abc import Generator
Expand Down Expand Up @@ -109,7 +108,11 @@ def molecule_data(
_molecule_verifier_section_data,
]

return functools.reduce(lambda x, y: util.merge_dicts(x, y), fixtures)
merged_dict = {}
for fixture in fixtures:
merged_dict.update(fixture)

return merged_dict


@pytest.fixture()
Expand Down

0 comments on commit 913f474

Please sign in to comment.