Skip to content

Commit

Permalink
Made should_panic test more specific
Browse files Browse the repository at this point in the history
  • Loading branch information
Azrenbeth authored and Azrenbeth committed Aug 12, 2021
1 parent 3216837 commit 2669ddd
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/compressor.rs
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ impl Level {
// If we're referencing the previous head then increment our chain
// length estimate
if !self.has_space() {
panic!("Tried to add to a already full level");
panic!("Tried to add to an already full level");
}

self.current_chain_length += 1;
Expand Down Expand Up @@ -270,7 +270,7 @@ mod level_tests {
}

#[test]
#[should_panic]
#[should_panic(expected="Tried to add to an already full level")]
fn update_panics_if_adding_and_too_full() {
let mut l = Level::new(5);
l.update(1, true);
Expand Down

0 comments on commit 2669ddd

Please sign in to comment.