()
| 930 | #[test] |
| 931 | #[file_serial] |
| 932 | fn test_add_run_file_not_found() { |
| 933 | let _guard = DirGuard::new(); |
| 934 | |
| 935 | let temp_dir = tempfile::tempdir().unwrap(); |
| 936 | let repo_path = temp_dir.path(); |
| 937 | |
| 938 | // Initialize repository and drop to release lock |
| 939 | { |
| 940 | let _repo = Repository::init(repo_path).unwrap(); |
| 941 | } |
| 942 | |
| 943 | std::env::set_current_dir(repo_path).unwrap(); |
| 944 | |
| 945 | let add = Add::new().with_files(vec!["nonexistent.txt"]); |
| 946 | let result = add.run(); |
| 947 | |
| 948 | // Should fail because file doesn't exist |
| 949 | assert!(result.is_err()); |
| 950 | } |
| 951 | |
| 952 | #[test] |
| 953 | #[file_serial] |
nothing calls this directly
no test coverage detected