MCPcopy Create free account
hub / github.com/ElementsProject/elements / dump_help

Method dump_help

test/functional/rpc_help.py:116–123  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

114 assert_equal(titles, sorted(components))
115
116 def dump_help(self):
117 dump_dir = os.path.join(self.options.tmpdir, 'rpc_help_dump')
118 os.mkdir(dump_dir)
119 calls = [line.split(' ', 1)[0] for line in self.nodes[0].help().splitlines() if line and not line.startswith('==')]
120 for call in calls:
121 with open(os.path.join(dump_dir, call), 'w', encoding='utf-8') as f:
122 # Make sure the node can generate the help at runtime without crashing
123 f.write(self.nodes[0].help(call))
124
125 def wallet_help(self):
126 assert 'getnewaddress ( "label" "address_type" )' in self.nodes[0].help('getnewaddress')

Callers 1

run_testMethod · 0.95

Calls 3

helpMethod · 0.80
joinMethod · 0.45
writeMethod · 0.45

Tested by

no test coverage detected