Skip to content

Commit

Permalink
add rust doc, update should panic
Browse files Browse the repository at this point in the history
  • Loading branch information
greged93 committed Sep 21, 2023
1 parent f076803 commit 46104a2
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
1 change: 1 addition & 0 deletions crates/sequencer/src/sequencer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ use blockifier::state::state_api::{State, StateReader};
/// We bound S such that a mutable reference to S (&'a mut S)
/// must implement State and StateReader. The `for` keyword
/// indicates that the bound must hold for any lifetime 'a.
/// For more details, check out https://doc.rust-lang.org/nomicon/hrtb.html
pub struct Sequencer<S>
where
for<'a> &'a mut S: State + StateReader,
Expand Down
8 changes: 2 additions & 6 deletions crates/sequencer/src/state.rs
Original file line number Diff line number Diff line change
Expand Up @@ -219,9 +219,7 @@ mod tests {
}

#[test]
#[should_panic(
expected = "UndeclaredClassHash(ClassHash(StarkFelt(\"0x0000000000000000000000000000000000000000000000000000000000000001\")))"
)]
#[should_panic(expected = "UndeclaredClassHash")]
fn test_uninitialized_contract_class() {
// Given
let mut state = &mut State::default();
Expand All @@ -247,9 +245,7 @@ mod tests {
}

#[test]
#[should_panic(
expected = "UndeclaredClassHash(ClassHash(StarkFelt(\"0x0000000000000000000000000000000000000000000000000000000000000001\"))"
)]
#[should_panic(expected = "UndeclaredClassHash")]
fn test_uninitialized_compiled_class_hash() {
// Given
let mut state = &mut State::default();
Expand Down

0 comments on commit 46104a2

Please sign in to comment.