aboutsummaryrefslogtreecommitdiff
path: root/test/functional/interface_bitcoin_cli.py
diff options
context:
space:
mode:
authorpracticalswift <practicalswift@users.noreply.github.com>2018-03-19 22:26:38 +0100
committerpracticalswift <practicalswift@users.noreply.github.com>2018-03-19 22:44:43 +0100
commita2b2476e96b34cba2e413bb099bcef5e4165b29a (patch)
tree2870719f7cfdab436679335667d350987fe67d52 /test/functional/interface_bitcoin_cli.py
parentde04fde534997f15235ded46912806d47c615c23 (diff)
tests: Test connecting to a non-existing server
Diffstat (limited to 'test/functional/interface_bitcoin_cli.py')
-rwxr-xr-xtest/functional/interface_bitcoin_cli.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/test/functional/interface_bitcoin_cli.py b/test/functional/interface_bitcoin_cli.py
index a349e23791..f48874274d 100755
--- a/test/functional/interface_bitcoin_cli.py
+++ b/test/functional/interface_bitcoin_cli.py
@@ -35,6 +35,9 @@ class TestBitcoinCli(BitcoinTestFramework):
assert_equal(["foo", "bar"], self.nodes[0].cli('-rpcuser=%s' % user, '-stdin', '-stdinrpcpass', input=password + "\nfoo\nbar").echo())
assert_raises_process_error(1, "Incorrect rpcuser or rpcpassword", self.nodes[0].cli('-rpcuser=%s' % user, '-stdin', '-stdinrpcpass', input="foo").echo)
+ self.log.info("Test connecting to a non-existing server")
+ assert_raises_process_error(1, "Could not connect to the server", self.nodes[0].cli('-rpcport=1').echo)
+
self.log.info("Make sure that -getinfo with arguments fails")
assert_raises_process_error(1, "-getinfo takes no arguments", self.nodes[0].cli('-getinfo').help)