()
| 410 | |
| 411 | #[test] |
| 412 | fn test_binary_content() { |
| 413 | let (repo, _temp, repo_path) = create_test_repo(); |
| 414 | |
| 415 | // Create a file with binary content |
| 416 | let binary_content: Vec<u8> = vec![0x00, 0x01, 0x02, 0xFF, 0xFE, 0xFD]; |
| 417 | let file_path = repo_path.join("binary.bin"); |
| 418 | fs::write(&file_path, &binary_content).expect("Failed to write binary file"); |
| 419 | repo.add("binary.bin", Default::default()) |
| 420 | .expect("Failed to add binary file"); |
| 421 | let hash = record_change(&repo, "Add binary file"); |
| 422 | |
| 423 | let after = repo |
| 424 | .get_file_content_after_change("binary.bin", &hash) |
| 425 | .expect("Failed to get after"); |
| 426 | |
| 427 | assert!(after.is_some(), "Binary content should be retrievable"); |
| 428 | assert_eq!( |
| 429 | after.unwrap(), |
| 430 | binary_content, |
| 431 | "Binary content should match exactly" |
| 432 | ); |
| 433 | } |
| 434 | |
| 435 | #[test] |
| 436 | #[ignore = "large-file integration case disabled pending faster default-path validation"] |
nothing calls this directly
no test coverage detected