mirror of
https://github.com/Aider-AI/aider.git
synced 2025-05-29 16:54:59 +00:00
fix: simplify ESLint Windows test mock
This commit is contained in:
parent
15abe6b921
commit
65fd6b444c
1 changed files with 1 additions and 4 deletions
|
@ -23,10 +23,7 @@ class TestLinter(unittest.TestCase):
|
|||
|
||||
@patch("pathlib.Path.is_file")
|
||||
def test_check_eslint_windows(self, mock_is_file):
|
||||
def side_effect(path):
|
||||
return str(path).endswith("eslint.cmd")
|
||||
|
||||
mock_is_file.side_effect = side_effect
|
||||
mock_is_file.return_value = True
|
||||
self.linter._check_eslint()
|
||||
self.assertIn("typescript", self.linter.languages)
|
||||
self.assertTrue(self.linter.languages["typescript"].endswith('eslint.cmd" --format unix'))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue