Skip to content

Commit

Permalink
ruff my imports
Browse files Browse the repository at this point in the history
  • Loading branch information
anthonykim1 committed Jan 22, 2025
1 parent b39dcd1 commit f9e2f85
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions python_files/tests/test_shell_integration.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
import platform
import sys
from unittest.mock import Mock

import pythonrc

is_wsl = "microsoft-standard-WSL" in platform.release()
Expand Down Expand Up @@ -61,15 +62,19 @@ def test_excepthook_call():
hooks.my_excepthook("mock_type", "mock_value", "mock_traceback")
mock_excepthook.assert_called_once_with("mock_type", "mock_value", "mock_traceback")


if sys.platform == "darwin":

def test_print_statement_darwin(monkeypatch):
importlib.reload(pythonrc)
with monkeypatch.context() as m:
m.setattr("builtins.print", Mock())
importlib.reload(sys.modules["pythonrc"])
print.assert_any_call("Cmd click to launch VS Code Native REPL")


if sys.platform == "win32":

def test_print_statement_non_darwin(monkeypatch):
importlib.reload(pythonrc)
with monkeypatch.context() as m:
Expand Down

0 comments on commit f9e2f85

Please sign in to comment.