File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change 1313import pytest
1414
1515from vcspull ._internal .config_reader import DuplicateAwareConfigReader
16+ from vcspull ._internal .private_path import PrivatePath
1617from vcspull .cli .add import add_repo , create_add_subparser , handle_add_command
17- from vcspull .util import contract_user_home
1818
1919if t .TYPE_CHECKING :
2020 import pathlib
@@ -706,7 +706,7 @@ def test_handle_add_command_path_mode(
706706 handle_add_command (args )
707707
708708 log_output = caplog .text
709- contracted_path = contract_user_home ( repo_path )
709+ contracted_path = str ( PrivatePath ( repo_path ) )
710710
711711 assert "Found new repository to import" in log_output
712712 assert contracted_path in log_output
@@ -715,7 +715,7 @@ def test_handle_add_command_path_mode(
715715 normalized_log = normalized_log .replace (str (repo_path ), "<repo_path>" )
716716 normalized_log = re .sub (r"add\.py:\d+" , "add.py:<line>" , normalized_log )
717717 if preserve_config_path_in_log :
718- assert contract_user_home ( config_file ) in log_output
718+ assert str ( PrivatePath ( config_file ) ) in log_output
719719 snapshot .assert_match (
720720 {
721721 "test_id" : test_id ,
You can’t perform that action at this time.
0 commit comments