()
| 691 | |
| 692 | #[test] |
| 693 | fn test_record_files_populated() { |
| 694 | let graph = sherpa_graph(); |
| 695 | let tmp = tempfile::tempdir().unwrap(); |
| 696 | let record = to_agent_trace_record(&graph, tmp.path()); |
| 697 | |
| 698 | assert_eq!(record.files.len(), 1); |
| 699 | assert_eq!(record.files[0].path, "src/index.ts"); |
| 700 | assert_eq!(record.files[0].conversations.len(), 1); |
| 701 | |
| 702 | let conv = &record.files[0].conversations[0]; |
| 703 | assert!(conv.url.contains("tiny-star-8412")); |
| 704 | assert_eq!(conv.contributor.contributor_type, "ai"); |
| 705 | assert_eq!(conv.ranges[0].start_line, 1); |
| 706 | assert_eq!(conv.ranges[0].end_line, 12); |
| 707 | |
| 708 | // todo related ref |
| 709 | assert!(conv.related.iter().any(|r| r.ref_type == "todo")); |
| 710 | } |
| 711 | |
| 712 | #[test] |
| 713 | fn test_append_and_read_back() { |
nothing calls this directly
no test coverage detected