Skip to content

Commit

Permalink
fix timestamp tests
Browse files Browse the repository at this point in the history
  • Loading branch information
yash-atreya committed Oct 22, 2024
1 parent cef9b2a commit 2fdbd51
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion crates/anvil/tests/it/anvil_api.rs
Original file line number Diff line number Diff line change
Expand Up @@ -315,7 +315,7 @@ async fn test_set_next_timestamp() {
let next = provider.get_block(BlockId::default(), false.into()).await.unwrap().unwrap();
assert_eq!(next.header.number, 2);

assert!(next.header.timestamp > block.header.timestamp);
assert!(next.header.timestamp >= block.header.timestamp);
}

#[tokio::test(flavor = "multi_thread")]
Expand Down
2 changes: 1 addition & 1 deletion crates/anvil/tests/it/fork.rs
Original file line number Diff line number Diff line change
Expand Up @@ -897,7 +897,7 @@ async fn test_fork_block_timestamp() {
api.anvil_mine(Some(U256::from(1)), None).await.unwrap();
let latest_block = api.block_by_number(BlockNumberOrTag::Latest).await.unwrap().unwrap();

assert!(initial_block.header.timestamp < latest_block.header.timestamp);
assert!(initial_block.header.timestamp <= latest_block.header.timestamp);
}

#[tokio::test(flavor = "multi_thread")]
Expand Down

0 comments on commit 2fdbd51

Please sign in to comment.