diff options
author | Daniƫl van Noord <13665637+DanielNoord@users.noreply.github.com> | 2022-05-10 11:38:53 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-05-10 11:38:53 +0200 |
commit | 7c915217b0513b34c179c409cff983352f685bf5 (patch) | |
tree | 8b66f795e83405e698453ecc3051fdc25c42576d /tests/test_self.py | |
parent | 133e2e59394528e3c2c16fd7ea921796bfcbef8d (diff) | |
download | pylint-git-7c915217b0513b34c179c409cff983352f685bf5.tar.gz |
Use main instead of master as main checker name (#6569)
Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com>
Diffstat (limited to 'tests/test_self.py')
-rw-r--r-- | tests/test_self.py | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/tests/test_self.py b/tests/test_self.py index 813a1dbac..3241f547a 100644 --- a/tests/test_self.py +++ b/tests/test_self.py @@ -1174,7 +1174,7 @@ class TestRunTC: rcfile = tmpdir / "pylintrc" rcfile_contents = textwrap.dedent( f""" - [MASTER] + [MAIN] output={output_file} """ ) @@ -1334,7 +1334,8 @@ class TestCallbackOptions: encoding="utf-8", check=False, ) - assert "[MASTER]" in process.stdout + assert "[MAIN]" in process.stdout + assert "[MASTER]" not in process.stdout assert "profile" not in process.stdout args = _add_rcfile_default_pylintrc(["--generate-rcfile"]) process_two = subprocess.run( @@ -1370,10 +1371,10 @@ class TestCallbackOptions: # Get rid of the pesky messages that pylint emits if the # configuration file is not found. pattern = rf"\[{MAIN_CHECKER_NAME.upper()}" - master = re.search(pattern, output) - assert master is not None, f"{pattern} not found in {output}" + main = re.search(pattern, output) + assert main is not None, f"{pattern} not found in {output}" - out = StringIO(output[master.start() :]) + out = StringIO(output[main.start() :]) parser = configparser.RawConfigParser() parser.read_file(out) messages = utils._splitstrip(parser.get("MESSAGES CONTROL", "disable")) @@ -1394,7 +1395,8 @@ class TestCallbackOptions: encoding="utf-8", check=False, ) - assert "[tool.pylint.master]" in process.stdout + assert "[tool.pylint.main]" in process.stdout + assert "[tool.pylint.master]" not in process.stdout assert '"positional arguments"' not in process.stdout assert '"optional arguments"' not in process.stdout assert 'preferred-modules = ["a:b"]' in process.stdout |