erigon-pulse/cmd/devnet/requests/admin.go
Leonard Chinonso f76736e14a
Implemented mining of contract transactions on the devnet tool (#6102)
- Added a new method and type for contract transactions.
- Added functions to emit fallback events from contract transactions.
- Added GetLogs request generator
- Added tests for GetLogs request generator
2022-11-22 20:28:53 +07:00

20 lines
468 B
Go

package requests
import (
"fmt"
"github.com/ledgerwatch/erigon/cmd/devnet/models"
"github.com/ledgerwatch/erigon/p2p"
)
func AdminNodeInfo(reqId int) (p2p.NodeInfo, error) {
reqGen := initialiseRequestGenerator(reqId)
var b models.AdminNodeInfoResponse
if res := reqGen.Erigon(models.AdminNodeInfo, reqGen.GetAdminNodeInfo(), &b); res.Err != nil {
return p2p.NodeInfo{}, fmt.Errorf("failed to get admin node info: %v", res.Err)
}
return b.Result, nil
}