Skip to content

Commit

Permalink
Fix tests now that we capture warnings and they're returned in state …
Browse files Browse the repository at this point in the history
…results

Signed-off-by: Pedro Algarvio <palgarvio@vmware.com>
  • Loading branch information
s0undt3ch committed Dec 14, 2023
1 parent 0fd8262 commit 260b5ed
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions tests/pytests/functional/states/file/test_symlink.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,12 @@ def test_symlink(file, tmp_path):
"name": str(symlink),
"changes": {"new": str(symlink)},
"result": True,
"comment": "Created new symlink {} -> {}".format(symlink, target),
"comment": f"Created new symlink {symlink} -> {target}",
}
assert ret.filtered == expected
filtered_return = ret.filtered
# Remove any warnings since that's not what we're testing
filtered_return.pop("warnings", None)
assert filtered_return == expected
assert symlink.exists()
assert symlink.is_symlink()

Expand Down

0 comments on commit 260b5ed

Please sign in to comment.