ok/jj
1
0
Fork 0
forked from mirrors/jj

tests: use OS directory separator in path when writing files to working copy

This commit is contained in:
Martin von Zweigbergk 2021-05-16 21:14:18 -07:00
parent 6233782914
commit 45bb748f9b

View file

@ -126,7 +126,7 @@ pub fn write_working_copy_file(repo: &ReadonlyRepo, path: &FileRepoPath, content
.write(true) .write(true)
.create(true) .create(true)
.truncate(true) .truncate(true)
.open(repo.working_copy_path().join(path.to_internal_string())) .open(path.to_fs_path(repo.working_copy_path()))
.unwrap(); .unwrap();
file.write_all(contents.as_bytes()).unwrap(); file.write_all(contents.as_bytes()).unwrap();
} }