funga

Signer and keystore daemon and library for cryptocurrency software development
Log | Files | Refs | README | LICENSE

commit 031bc5a618c3e44aaf8ef649e96eea93be237000
parent e606384ed27f25a11ffed1c1fd97fcb5dc1c34f9
Author: nolash <dev@holbrook.no>
Date:   Sun, 10 Oct 2021 09:57:34 +0200

Make cli test pass

Diffstat:
Mfunga/eth/cli/handle.py | 6+++---
Mfunga/eth/cli/jsonrpc.py | 2+-
Mfunga/eth/keystore/dict.py | 1+
Mtests/test_cli.py | 10+++++-----
4 files changed, 10 insertions(+), 9 deletions(-)

diff --git a/funga/eth/cli/handle.py b/funga/eth/cli/handle.py @@ -11,12 +11,12 @@ from jsonrpc.exceptions import ( from hexathon import add_0x # local imports -from crypto_dev_signer.eth.transaction import EIP155Transaction -from crypto_dev_signer.error import ( +from funga.eth.transaction import EIP155Transaction +from funga.error import ( UnknownAccountError, SignerError, ) -from crypto_dev_signer.cli.jsonrpc import jsonrpc_ok +from funga.eth.cli.jsonrpc import jsonrpc_ok from .jsonrpc import ( jsonrpc_error, is_valid_json, diff --git a/funga/eth/cli/jsonrpc.py b/funga/eth/cli/jsonrpc.py @@ -1,5 +1,5 @@ # local imports -from crypto_dev_signer.error import UnknownAccountError +from funga.error import UnknownAccountError def jsonrpc_error(rpc_id, err): diff --git a/funga/eth/keystore/dict.py b/funga/eth/keystore/dict.py @@ -19,6 +19,7 @@ logg = logging.getLogger(__name__) class DictKeystore(EthKeystore): def __init__(self): + super(DictKeystore, self).__init__() self.keys = {} diff --git a/tests/test_cli.py b/tests/test_cli.py @@ -7,10 +7,10 @@ import os from hexathon import strip_0x # local imports -from crypto_dev_signer.eth.signer import ReferenceSigner -from crypto_dev_signer.keystore.dict import DictKeystore -from crypto_dev_signer.cli.handle import SignRequestHandler -from crypto_dev_signer.eth.transaction import EIP155Transaction +from funga.eth.signer import EIP155Signer +from funga.eth.keystore.dict import DictKeystore +from funga.eth.cli.handle import SignRequestHandler +from funga.eth.transaction import EIP155Transaction logging.basicConfig(level=logging.DEBUG) logg = logging.getLogger() @@ -25,7 +25,7 @@ class TestCli(unittest.TestCase): #pk_getter = pkGetter(pk) self.keystore = DictKeystore() SignRequestHandler.keystore = self.keystore - self.signer = ReferenceSigner(self.keystore) + self.signer = EIP155Signer(self.keystore) SignRequestHandler.signer = self.signer self.handler = SignRequestHandler()