Skip to content

Commit

Permalink
Rename whisper-cli binary to whisper (openethereum#8579)
Browse files Browse the repository at this point in the history
* rename whisper-cli binary to whisper

* fix tests
  • Loading branch information
niklasad1 authored and VladLupashevskyi committed May 23, 2018
1 parent a5669ae commit 9748b53
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 7 deletions.
4 changes: 3 additions & 1 deletion whisper/cli/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
[package]
name = "whisper-cli"
description = "Whisper command line interface"
version = "0.1.0"
authors = ["Parity Technologies <[email protected]>"]
license = "GPL-3.0"

[dependencies]
ethcore-network-devp2p = { path = "../../util/network-devp2p" }
Expand All @@ -18,5 +20,5 @@ jsonrpc-http-server = { git = "https://github.com/paritytech/jsonrpc.git", branc
log = "0.3"

[[bin]]
name = "whisper-cli"
name = "whisper"
path = "src/main.rs"
12 changes: 6 additions & 6 deletions whisper/cli/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ use jsonrpc_http_server::{AccessControlAllowOrigin, DomainsValidation};
const POOL_UNIT: usize = 1024 * 1024;
const USAGE: &'static str = r#"
Whisper CLI.
Copyright 2017 Parity Technologies (UK) Ltd
Copyright 2018 Parity Technologies (UK) Ltd
Usage:
whisper [options]
Expand All @@ -56,7 +56,7 @@ Options:
--whisper-pool-size SIZE Specify Whisper pool size [default: 10].
-p, --port PORT Specify which RPC port to use [default: 8545].
-a, --address ADDRESS Specify which address to use [default: 127.0.0.1].
-l, --log LEVEL Specify the logging level. Must conform to the same format as RUST_LOG [default: Error].
-l, --log LEVEL Specify the logging level. Must conform to the same format as RUST_LOG [default: Error].
-h, --help Display this message and exit.
"#;

Expand Down Expand Up @@ -259,7 +259,7 @@ mod tests {

#[test]
fn invalid_argument() {
let command = vec!["whisper-cli", "--foo=12"]
let command = vec!["whisper", "--foo=12"]
.into_iter()
.map(Into::into)
.collect::<Vec<String>>();
Expand All @@ -270,7 +270,7 @@ mod tests {
#[test]
#[ignore]
fn privileged_port() {
let command = vec!["whisper-cli", "--port=3"]
let command = vec!["whisper", "--port=3"]
.into_iter()
.map(Into::into)
.collect::<Vec<String>>();
Expand All @@ -280,7 +280,7 @@ mod tests {

#[test]
fn invalid_ip_address() {
let command = vec!["whisper-cli", "--address=x.x.x.x"]
let command = vec!["whisper", "--address=x.x.x.x"]
.into_iter()
.map(Into::into)
.collect::<Vec<String>>();
Expand All @@ -290,7 +290,7 @@ mod tests {

#[test]
fn invalid_whisper_pool_size() {
let command = vec!["whisper-cli", "--whisper-pool-size=-100000000000000000000000000000000000000"]
let command = vec!["whisper", "--whisper-pool-size=-100000000000000000000000000000000000000"]
.into_iter()
.map(Into::into)
.collect::<Vec<String>>();
Expand Down

0 comments on commit 9748b53

Please sign in to comment.