Repository navigation
restore invalid attestation test - #579
ImJeremyHe wants to merge 6 commits into
Conversation
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
39caa0b to
e0fa6a2
Compare
e9fa3f1 to
fbe2c86
Compare
| batchDriver := system.BatchSubmitter.TestDriver() | ||
| batchDriver.Espresso.Attestation = invalidAttestation | ||
| err = batchDriver.StartBatchSubmitting() | ||
| if err == nil { |
There was a problem hiding this comment.
Let us be more specific about the error, it should be related to the attestation no to some 200 error for example.
There was a problem hiding this comment.
for _, expectedMsg := range []string{
"could not register with BatchAuthenticator contract",
"failed to generate zk proof from nitro attestation",
"received non-200 response: 400",
} {
if !strings.Contains(err.Error(), expectedMsg) {
t.Fatalf("error message does not contain expected message %q:\ngot: %q", expectedMsg, err.Error())
}
}
Added these lines below
| t.Fatalf("batcher should've failed to register with invalid attestation but got nil error") | ||
| } | ||
|
|
||
| expectedMsg := "could not register with BatchAuthenticator contract" |
There was a problem hiding this comment.
Could we check for more specific error types here? There are several failure paths, so we should ideally verify the reasons for which that startup failed.
There was a problem hiding this comment.
For example, a proof-decoding error or a failed L1 registration transaction would also match this message. Could we check the underlying cause too, so the assertion specifically identifies rejection by the attestation verifier?
fbe2c86 to
8c5c79f
Compare
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
8c5c79f to
0d66640
Compare
Uh oh!
There was an error while loading. Please reload this page.