wallet_dump_private_key api and client rpc test, with some clean up to last review comments.