From 66c9b207fc95406b237c3b808466fc2c324a6731 Mon Sep 17 00:00:00 2001 From: GomathiselviS Date: Thu, 26 Aug 2021 14:09:25 -0400 Subject: Fix pylint sanity issues (#204) Fix pylint sanity issues Signed-off-by: GomathiselviS gomathiselvi@gmail.com SUMMARY ISSUE TYPE Bugfix Pull Request Docs Pull Request Feature Pull Request New Module Pull Request COMPONENT NAME ADDITIONAL INFORMATION Reviewed-by: Nilashish Chakraborty Reviewed-by: None --- tests/unit/mock/loader.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'tests/unit/mock') diff --git a/tests/unit/mock/loader.py b/tests/unit/mock/loader.py index c21188ee..aea5df56 100644 --- a/tests/unit/mock/loader.py +++ b/tests/unit/mock/loader.py @@ -46,12 +46,12 @@ class DictDataLoader(DataLoader): # TODO: the real _get_file_contents returns a bytestring, so we actually convert the # unicode/text it's created with to utf-8 - def _get_file_contents(self, path): - path = to_text(path) + def _get_file_contents(self, file_name): + path = to_text(file_name) if path in self._file_mapping: - return (to_bytes(self._file_mapping[path]), False) + return (to_bytes(self._file_mapping[file_name]), False) else: - raise AnsibleParserError("file not found: %s" % path) + raise AnsibleParserError("file not found: %s" % file_name) def path_exists(self, path): path = to_text(path) -- cgit v1.2.3