Add random mutation tests

This commit is contained in:
Max Brunsfeld 2019-01-25 12:05:21 -08:00
parent e305012b31
commit 233d616ebf
12 changed files with 443 additions and 127 deletions

View file

@ -40,13 +40,15 @@ pub fn stop_recording() {
recorder.enabled = false;
if !recorder.outstanding_allocations.is_empty() {
let mut allocation_indices = recorder
.outstanding_allocations
.iter()
.map(|e| e.1)
.collect::<Vec<_>>();
allocation_indices.sort_unstable();
panic!(
"Leaked allocation indices: {:?}",
recorder
.outstanding_allocations
.iter()
.map(|e| e.1)
.collect::<Vec<_>>()
allocation_indices
);
}
}