Move ethcallsigs to tests to confirm stand alone rpc setup
This commit is contained in:
parent
8b007ff2f4
commit
7aff489622
|
@ -1,4 +1,7 @@
|
|||
import ../ rpcclient, ../ rpcserver, unittest, asyncdispatch, json, tables
|
||||
import ../ rpcclient, ../ rpcserver
|
||||
import unittest, asyncdispatch, json, tables
|
||||
from os import getCurrentDir, DirSep
|
||||
from strutils import rsplit
|
||||
|
||||
# TODO: dummy implementations of RPC calls handled in async fashion.
|
||||
# TODO: check required json parameters like version are being raised
|
||||
|
@ -6,6 +9,11 @@ var srv = sharedRpcServer()
|
|||
srv.address = "localhost"
|
||||
srv.port = Port(8545)
|
||||
|
||||
import stint
|
||||
|
||||
# generate all client ethereum rpc calls
|
||||
createRpcSigs(currentSourcePath.rsplit(DirSep, 1)[0] & DirSep & "ethcallsigs.nim")
|
||||
|
||||
srv.rpc("myProc") do(input: string, data: array[0..3, int]):
|
||||
result = %("Hello " & input & " data: " & $data)
|
||||
|
||||
|
|
Loading…
Reference in New Issue