Skip to content

Commit

Permalink
pre-commit fix
Browse files Browse the repository at this point in the history
  • Loading branch information
benjisho committed Jan 27, 2024
1 parent 79b73bd commit c01977b
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion test_runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,14 @@


# Windows doesn't like / in paths, so we need to convert to \
# If we're on Windows, convert to Windows path,
# and if we're not on Windows, just return the path.
def convert_to_windows_path(path: Path) -> Path:
# If we're on Windows, convert to Windows path, and if we're not on Windows, just return the path.
if path.is_absolute() and path.drive:
return Path(path.drive + path.as_posix().replace("/", "\\"))
return path


BANDERSNATCH_EXE = Path(
which("bandersnatch") or which("bandersnatch.exe") or "bandersnatch"
)
Expand Down

0 comments on commit c01977b

Please sign in to comment.