File tree Expand file tree Collapse file tree 2 files changed +3
-7
lines changed
Expand file tree Collapse file tree 2 files changed +3
-7
lines changed Original file line number Diff line number Diff line change @@ -672,7 +672,8 @@ impl GlobalContext {
672672 . to_string( ) ,
673673 ) ,
674674 ( "{workspace-path-hash}" , {
675- let hash = crate :: util:: hex:: short_hash( & workspace_manifest_path) ;
675+ let real_path = std:: fs:: canonicalize( workspace_manifest_path) ?;
676+ let hash = crate :: util:: hex:: short_hash( & real_path) ;
676677 format!( "{}{}{}" , & hash[ 0 ..2 ] , std:: path:: MAIN_SEPARATOR , & hash[ 2 ..] )
677678 } ) ,
678679 ] ;
Original file line number Diff line number Diff line change @@ -673,13 +673,8 @@ fn template_workspace_path_hash_should_handle_symlink() {
673673 let symlink_hash_dir = parse_workspace_manifest_path_hash ( & foo_dir) ;
674674 verify_layouts ( & p, & symlink_hash_dir) ;
675675
676- // Verify the current behavior:
677- // unix: hash dir created from the symlinked and non-symlinked dirs are the same.
678- #[ cfg( unix) ]
676+ // Verify the hash dir created from the symlinked and non-symlinked dirs are the same.
679677 assert_eq ! ( original_hash_dir, symlink_hash_dir) ;
680- // windows: hash dir created from the symlinked and non-symlinked dirs are different.
681- #[ cfg( windows) ]
682- assert_ne ! ( original_hash_dir, symlink_hash_dir) ;
683678
684679 fn verify_layouts ( p : & Project , build_dir_parent : & PathBuf ) {
685680 let build_dir = build_dir_parent. as_path ( ) . join ( "build-dir" ) ;
You can’t perform that action at this time.
0 commit comments