aboutsummaryrefslogtreecommitdiff
path: root/utils
diff options
context:
space:
mode:
authormoneromooo-monero <moneromooo-monero@users.noreply.github.com>2019-04-29 21:44:01 +0000
committermoneromooo-monero <moneromooo-monero@users.noreply.github.com>2019-09-17 11:38:22 +0000
commit0dc49fc91826ec863b998a2b203352f837fa49cb (patch)
tree65736732a8d9d0bbbebc0dc056fe39127420514b /utils
parentfunctional_tests: add spend proof tests (diff)
downloadmonero-0dc49fc91826ec863b998a2b203352f837fa49cb.tar.xz
functional_tests: add wallet password change, store and tag tests
Diffstat (limited to 'utils')
-rw-r--r--utils/python-rpc/framework/wallet.py84
1 files changed, 84 insertions, 0 deletions
diff --git a/utils/python-rpc/framework/wallet.py b/utils/python-rpc/framework/wallet.py
index 1949eddf0..7aabb5f29 100644
--- a/utils/python-rpc/framework/wallet.py
+++ b/utils/python-rpc/framework/wallet.py
@@ -350,6 +350,34 @@ class Wallet(object):
}
return self.rpc.send_json_rpc_request(close_wallet)
+ def change_wallet_password(self, old_password, new_password):
+ change_wallet_password = {
+ 'method': 'change_wallet_password',
+ 'params' : {
+ 'old_password': old_password,
+ 'new_password': new_password,
+ },
+ 'jsonrpc': '2.0',
+ 'id': '0'
+ }
+ return self.rpc.send_json_rpc_request(change_wallet_password)
+
+ def store(self):
+ store = {
+ 'method': 'store',
+ 'jsonrpc': '2.0',
+ 'id': '0'
+ }
+ return self.rpc.send_json_rpc_request(store)
+
+ def stop_wallet(self):
+ stop_wallet = {
+ 'method': 'stop_wallet',
+ 'jsonrpc': '2.0',
+ 'id': '0'
+ }
+ return self.rpc.send_json_rpc_request(stop_wallet)
+
def refresh(self):
refresh = {
'method': 'refresh',
@@ -806,6 +834,62 @@ class Wallet(object):
}
return self.rpc.send_json_rpc_request(validate_address)
+ def get_accounts(self, tag):
+ get_accounts = {
+ 'method': 'get_accounts',
+ 'params': {
+ 'tag': tag,
+ },
+ 'jsonrpc': '2.0',
+ 'id': '0'
+ }
+ return self.rpc.send_json_rpc_request(get_accounts)
+
+ def get_account_tags(self):
+ get_account_tags = {
+ 'method': 'get_account_tags',
+ 'params': {
+ },
+ 'jsonrpc': '2.0',
+ 'id': '0'
+ }
+ return self.rpc.send_json_rpc_request(get_account_tags)
+
+ def tag_accounts(self, tag, accounts = []):
+ tag_accounts = {
+ 'method': 'tag_accounts',
+ 'params': {
+ 'tag': tag,
+ 'accounts': accounts,
+ },
+ 'jsonrpc': '2.0',
+ 'id': '0'
+ }
+ return self.rpc.send_json_rpc_request(tag_accounts)
+
+ def untag_accounts(self, accounts = []):
+ untag_accounts = {
+ 'method': 'untag_accounts',
+ 'params': {
+ 'accounts': accounts,
+ },
+ 'jsonrpc': '2.0',
+ 'id': '0'
+ }
+ return self.rpc.send_json_rpc_request(untag_accounts)
+
+ def set_account_tag_description(self, tag, description):
+ set_account_tag_description = {
+ 'method': 'set_account_tag_description',
+ 'params': {
+ 'tag': tag,
+ 'description': description,
+ },
+ 'jsonrpc': '2.0',
+ 'id': '0'
+ }
+ return self.rpc.send_json_rpc_request(set_account_tag_description)
+
def start_mining(self, threads_count, do_background_mining = False, ignore_battery = False):
start_mining = {
'method': 'start_mining',