fix empty auth test

This commit is contained in:
Sina Mahmoodi 2025-02-05 16:41:01 +01:00
parent 3ed2d35890
commit 90dcd2adab

View file

@ -86,6 +86,9 @@ func (tt *TransactionTest) Run(config *params.ChainConfig) error {
if requiredGas > tx.Gas() {
return sender, hash, 0, fmt.Errorf("insufficient gas ( %d < %d )", tx.Gas(), requiredGas)
}
if auth := tx.SetCodeAuthorizations(); auth != nil && len(auth) == 0 {
return sender, hash, requiredGas, fmt.Errorf("missing authorization")
}
hash = tx.Hash()
return sender, hash, requiredGas, nil
}