Skip to content

Commit

Permalink
TestMessageAboutScriptsNotOnPATH: make working on windows again secon…
Browse files Browse the repository at this point in the history
…d try
  • Loading branch information
lorddavidiii committed Jan 11, 2023
1 parent c347c45 commit 04bcf51
Showing 1 changed file with 13 additions and 11 deletions.
24 changes: 13 additions & 11 deletions tests/unit/test_wheel.py
Original file line number Diff line number Diff line change
Expand Up @@ -536,7 +536,7 @@ def test_single_script__single_dir_not_on_PATH(self) -> None:
retval = self._template(paths=["/a/b", "/c/d/bin"], scripts=["/c/d/foo"])
assert retval is not None
assert "--no-warn-script-location" in retval
assert f"foo is installed in '{Path('/c/d')}'" in retval
assert f"foo is installed in '{Path('/c/d').resolve()}'" in retval
assert self.tilde_warning_msg not in retval

def test_two_script__single_dir_not_on_PATH(self) -> None:
Expand All @@ -545,7 +545,7 @@ def test_two_script__single_dir_not_on_PATH(self) -> None:
)
assert retval is not None
assert "--no-warn-script-location" in retval
assert f"baz and foo are installed in '{Path('/c/d')}'" in retval
assert f"baz and foo are installed in '{Path('/c/d').resolve()}'" in retval
assert self.tilde_warning_msg not in retval

def test_multi_script__multi_dir_not_on_PATH(self) -> None:
Expand All @@ -555,8 +555,8 @@ def test_multi_script__multi_dir_not_on_PATH(self) -> None:
)
assert retval is not None
assert "--no-warn-script-location" in retval
assert f"bar, baz and foo are installed in '{Path('/c/d')}'" in retval
assert f"spam is installed in '{Path('/a/b/c')}'" in retval
assert f"bar, baz and foo are installed in '{Path('/c/d').resolve()}'" in retval
assert f"spam is installed in '{Path('/a/b/c').resolve()}'" in retval
assert self.tilde_warning_msg not in retval

def test_multi_script_all__multi_dir_not_on_PATH(self) -> None:
Expand All @@ -566,8 +566,8 @@ def test_multi_script_all__multi_dir_not_on_PATH(self) -> None:
)
assert retval is not None
assert "--no-warn-script-location" in retval
assert f"bar, baz and foo are installed in '{Path('/c/d')}'" in retval
assert f"eggs and spam are installed in '{Path('/a/b/c')}'" in retval
assert f"bar, baz and foo are installed in '{Path('/c/d').resolve()}'" in retval
assert f"eggs and spam are installed in '{Path('/a/b/c').resolve()}'" in retval
assert self.tilde_warning_msg not in retval

def test_two_script__single_dir_on_PATH(self) -> None:
Expand Down Expand Up @@ -644,9 +644,9 @@ def test_multi_script_all_tilde__multi_dir_not_on_PATH(self) -> None:
)
assert retval is not None
assert "--no-warn-script-location" in retval
assert f"bar, baz and foo are installed in '{Path('/c/d')}'" in retval
assert f"eggs and spam are installed in '{Path('/a/b/c')}'" in retval
assert f"tilde is installed in '{Path('/e/f')}'" in retval
assert f"bar, baz and foo are installed in '{Path('/c/d').resolve()}'" in retval
assert f"eggs and spam are installed in '{Path('/a/b/c').resolve()}'" in retval
assert f"tilde is installed in '{Path('/e/f').resolve()}'" in retval
assert self.tilde_warning_msg in retval

def test_multi_script_all_tilde_not_at_start__multi_dir_not_on_PATH(self) -> None:
Expand All @@ -662,8 +662,10 @@ def test_multi_script_all_tilde_not_at_start__multi_dir_not_on_PATH(self) -> Non
)
assert retval is not None
assert "--no-warn-script-location" in retval
assert f"bar, baz and foo are installed in '{Path('/c/d')}'" in retval
assert f"eggs and spam are installed in '{Path('/e/f~f/c')}'" in retval
assert f"bar, baz and foo are installed in '{Path('/c/d').resolve()}'" in retval
assert (
f"eggs and spam are installed in '{Path('/e/f~f/c').resolve()}'" in retval
)
assert self.tilde_warning_msg not in retval


Expand Down

0 comments on commit 04bcf51

Please sign in to comment.