cleanup: remove a few unnecessary borrows, as reported by Clippy

This commit is contained in:
Martin von Zweigbergk 2022-11-24 10:39:22 -08:00 committed by Martin von Zweigbergk
parent 84b924946f
commit 2a87815006
2 changed files with 2 additions and 2 deletions

View file

@ -63,7 +63,7 @@ fn test_init_external_git() {
let (canonical, uncanonical) = canonicalize(temp_dir.path());
let git_repo_path = uncanonical.join("git");
git2::Repository::init(&git_repo_path).unwrap();
std::fs::create_dir(&uncanonical.join("jj")).unwrap();
std::fs::create_dir(uncanonical.join("jj")).unwrap();
let (workspace, repo) =
Workspace::init_external_git(&settings, &uncanonical.join("jj"), &git_repo_path).unwrap();
assert!(repo.store().git_repo().is_some());

View file

@ -436,7 +436,7 @@ fn test_snapshot_special_file() {
std::fs::write(&file1_disk_path, "contents".as_bytes()).unwrap();
let file2_path = RepoPath::from_internal_string("file2");
let file2_disk_path = file2_path.to_fs_path(&workspace_root);
std::fs::write(&file2_disk_path, "contents".as_bytes()).unwrap();
std::fs::write(file2_disk_path, "contents".as_bytes()).unwrap();
let socket_disk_path = workspace_root.join("socket");
UnixListener::bind(&socket_disk_path).unwrap();
// Test the setup