mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-19 11:20:45 +00:00
new blocksigner contract
This commit is contained in:
parent
6a76879b85
commit
2677b33b78
2 changed files with 8 additions and 2 deletions
|
|
@ -162,7 +162,7 @@ func (b *SimulatedBackend) ForEachStorageAt(ctx context.Context, contract common
|
|||
b.mu.Lock()
|
||||
defer b.mu.Unlock()
|
||||
|
||||
if blockNumber != nil && blockNumber.Cmp(b.blockchain.CurrentBlock().Number()) != 0 {
|
||||
if blockNumber != nil && blockNumber.Cmp(b.blockchain.CurrentBlock().Number()) != 0 {
|
||||
return errBlockNumberUnsupported
|
||||
}
|
||||
statedb, _ := b.blockchain.State()
|
||||
|
|
|
|||
|
|
@ -47,5 +47,11 @@ func TestBlockSigner(t *testing.T) {
|
|||
for _, it := range signers {
|
||||
t.Log("signer", it.String())
|
||||
}
|
||||
|
||||
s, err := blockSigner.Sign(big.NewInt(1), byte0)
|
||||
if err != nil {
|
||||
t.Fatalf("can't sign: %v", err)
|
||||
}
|
||||
t.Log("tx data", s)
|
||||
contractBackend.Commit()
|
||||
}
|
||||
Loading…
Reference in a new issue