Skip to content

Commit

Permalink
feat: allow to replay a block without checking its trace
Browse files Browse the repository at this point in the history
  • Loading branch information
delehef committed Feb 28, 2024
1 parent 07e212e commit eeea4cd
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ public static void replay(String filename) {
}
ToyExecutionEnvironment.builder()
.build()
.replay(new BufferedReader(new InputStreamReader(stream)));
.replayAndCheck(new BufferedReader(new InputStreamReader(stream)));
}

@Test
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -122,9 +122,17 @@ public void replay(final Reader replayFile) {
return;
}
this.executeFrom(conflation);
}

public void replayAndCheck(final Reader replayFile) {
this.replay(replayFile);
this.checkTracer();
}

public Map<String, Integer> getLinesCount() {
return this.tracer.getModulesLineCount();
}

/**
* Loads the states and the conflation defined in a {@link ConflationSnapshot}, mimick the
* accounts, storage and blocks state as it was on the blockchain before the conflation played
Expand Down

0 comments on commit eeea4cd

Please sign in to comment.