Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 13 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,6 @@ ignore = [
"G", # flake8-logging-format
"RSE", # flake8-raise
"BLE", # flake8-blind-except (BLE)
"A", # flake8-builtins

##################################################################################################
# The ignored rules below should be removed once the code has been updated, they are included #
Expand Down Expand Up @@ -230,6 +229,19 @@ indent-style = "space"
skip-magic-trailing-comma = false
line-ending = "auto"


[tool.ruff.lint.flake8-builtins]
ignorelist = [
"id",
# Review and update builtin shadowing below this line
"filter",
"format",
"input",
"list",
"property",
]


[tool.ruff.lint.isort]
known-first-party = ["infrahub_sdk", "infrahub_ctl"]

Expand Down
6 changes: 3 additions & 3 deletions tests/unit/sdk/test_yaml.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,12 @@

def test_read_missing_file() -> None:
file_name = "i_do_not_exist.yml"
dir = here / "test_data"
full_path = dir / file_name
test_data_dir = here / "test_data"
full_path = test_data_dir / file_name
yaml_file = YamlFile(location=full_path)
yaml_file.load_content()
assert not yaml_file.valid
assert yaml_file.error_message == f"{file_name}: not found at {dir}"
assert yaml_file.error_message == f"{file_name}: not found at {test_data_dir}"


def test_read_incorrect_encoding() -> None:
Expand Down