Skip to content

Commit

Permalink
Fix test
Browse files Browse the repository at this point in the history
  • Loading branch information
gents83 committed Sep 22, 2023
1 parent fb13cc8 commit ac30622
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion tests/tests/mem_leaks.rs
Original file line number Diff line number Diff line change
Expand Up @@ -238,13 +238,15 @@ fn draw_test_with_reports(
assert_eq!(report.textures.num_allocated, 1);

let submit_index = ctx.queue.submit(Some(encoder.finish()));
ctx.device
.poll(wgpu::Maintain::WaitForSubmissionIndex(submit_index));

let global_report = ctx.instance.generate_report();
let report = global_report.hub_report();
assert_eq!(report.command_buffers.num_allocated, 0);

ctx.device
.poll(wgpu::Maintain::WaitForSubmissionIndex(submit_index));
.poll(wgpu::Maintain::Wait);

let global_report = ctx.instance.generate_report();
let report = global_report.hub_report();
Expand Down

0 comments on commit ac30622

Please sign in to comment.