(
#[case] input: &[u8],
#[case] expected_change_kind: ChangeKind,
#[case] expected_path_kind: PathKind,
#[case] changed_name: &[u8],
)
| 272 | )] |
| 273 | fn rsync_change_kind( |
| 274 | #[case] input: &[u8], |
| 275 | #[case] expected_change_kind: ChangeKind, |
| 276 | #[case] expected_path_kind: PathKind, |
| 277 | #[case] changed_name: &[u8], |
| 278 | ) -> TestResult { |
| 279 | let Report::PathChange { |
| 280 | change_kind, |
| 281 | path_kind, |
| 282 | path, |
| 283 | } = Report::parser(input)? |
| 284 | else { |
| 285 | panic!("rsync didn't report a change"); |
| 286 | }; |
| 287 | assert_eq!(change_kind, expected_change_kind); |
| 288 | assert_eq!(path_kind, expected_path_kind); |
| 289 | assert_eq!(path.as_os_str().as_bytes(), changed_name); |
| 290 | Ok(()) |
| 291 | } |
| 292 | |
| 293 | #[rstest] |
| 294 | #[case::attr_change(b".f+++++++++ file.name")] |
| 295 | #[case::changed_remotely(b"<f+++++++++ file.name")] |
nothing calls this directly
no outgoing calls
no test coverage detected