Skip to content

Commit

Permalink
add test
Browse files Browse the repository at this point in the history
  • Loading branch information
nibon7 committed Jan 10, 2024
1 parent 9f7b4bb commit c62060d
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/history/base.rs
Original file line number Diff line number Diff line change
Expand Up @@ -427,4 +427,13 @@ mod test {

Ok(())
}

#[test]
fn create_file_backed_history() {
use crate::HISTORY_SIZE;

assert!(crate::FileBackedHistory::new(0).is_err());
assert!(crate::FileBackedHistory::new(usize::MAX).is_err());
assert!(crate::FileBackedHistory::new(HISTORY_SIZE).is_ok());
}
}

0 comments on commit c62060d

Please sign in to comment.