mirror of
https://github.com/arnaucube/hermez-node.git
synced 2026-02-07 03:16:45 +01:00
Add ethclient full skeleton
This commit is contained in:
@@ -255,8 +255,8 @@ func (c *Coordinator) proveSequence() error {
|
||||
return err
|
||||
}
|
||||
batchInfo.SetProof(proof)
|
||||
callData := c.prepareCallDataForge(batchInfo)
|
||||
_, err = c.ethClient.ForgeCall(callData)
|
||||
forgeBatchArgs := c.prepareForgeBatchArgs(batchInfo)
|
||||
_, err = c.ethClient.RollupForgeBatch(forgeBatchArgs)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
@@ -306,6 +306,6 @@ func (c *Coordinator) shouldL1L2Batch() bool {
|
||||
return false
|
||||
}
|
||||
|
||||
func (c *Coordinator) prepareCallDataForge(batchInfo *BatchInfo) *common.CallDataForge {
|
||||
func (c *Coordinator) prepareForgeBatchArgs(batchInfo *BatchInfo) *eth.RollupForgeBatchArgs {
|
||||
return nil
|
||||
}
|
||||
|
||||
@@ -10,6 +10,7 @@ import (
|
||||
"github.com/hermeznetwork/hermez-node/db/historydb"
|
||||
"github.com/hermeznetwork/hermez-node/db/l2db"
|
||||
"github.com/hermeznetwork/hermez-node/db/statedb"
|
||||
"github.com/hermeznetwork/hermez-node/eth"
|
||||
"github.com/hermeznetwork/hermez-node/log"
|
||||
"github.com/hermeznetwork/hermez-node/txselector"
|
||||
"github.com/stretchr/testify/assert"
|
||||
@@ -50,7 +51,7 @@ func TestCoordinator(t *testing.T) {
|
||||
LoopInterval: 100 * time.Millisecond,
|
||||
}
|
||||
hdb := &historydb.HistoryDB{}
|
||||
c := NewCoordinator(conf, hdb, txsel, bb, nil)
|
||||
c := NewCoordinator(conf, hdb, txsel, bb, ð.Client{})
|
||||
c.Start()
|
||||
time.Sleep(1 * time.Second)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user