Skip to content

Commit

Permalink
Fix integration tests sometimes failing (#441)
Browse files Browse the repository at this point in the history
  • Loading branch information
noituri authored Mar 18, 2024
1 parent ecff6b1 commit 1b696a4
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion compositor_integration_tests/src/tests/simple.rs
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ pub fn simple_test() -> Result<()> {
compare_dumps(
&output_dump_from_disk,
&new_output_dump,
&[Duration::from_secs(1), Duration::from_secs(2)],
&[Duration::from_millis(500), Duration::from_millis(1500)],
20.0,
)?;

Expand Down
5 changes: 4 additions & 1 deletion compositor_integration_tests/src/validation.rs
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,10 @@ fn compare_video_dumps(
let diff_v = calculate_diff(&expected.data.v_plane, &actual.data.v_plane);

if diff_y > allowed_error || diff_u > allowed_error || diff_v > allowed_error {
return Err(anyhow::anyhow!("Frame mismatch"));
let pts = pts.as_micros();
return Err(anyhow::anyhow!(
"Frame mismatch. PTS: {pts}, Diff Y: {diff_y}, Diff U: {diff_u}, Diff V: {diff_v}"
));
}
}

Expand Down

0 comments on commit 1b696a4

Please sign in to comment.