diff options
author | Marcel Müller <neikos@neikos.email> | 2022-07-18 09:14:52 +0200 |
---|---|---|
committer | Matthias Beyer <mail@beyermatthias.de> | 2023-01-02 11:49:54 +0100 |
commit | ea793085aa27cdc3af4fe48bcc0e3f05d9bf6bfe (patch) | |
tree | 8fa124ed10c298aa404bfe90526db0e49d5a53a5 /mqtt-tester/src/main.rs | |
parent | c5cdd3795c5d8d67b9a07b3e3f64de828bc80af3 (diff) |
Add mqtt-testing library
This testing executable/framework servers a dual purpose:
- Test the cloudmqtt client independently of its implementation
- Share the testing framework with a wider audience
Signed-off-by: Marcel Müller <neikos@neikos.email>
Diffstat (limited to 'mqtt-tester/src/main.rs')
-rw-r--r-- | mqtt-tester/src/main.rs | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/mqtt-tester/src/main.rs b/mqtt-tester/src/main.rs new file mode 100644 index 0000000..23ab2d1 --- /dev/null +++ b/mqtt-tester/src/main.rs @@ -0,0 +1,34 @@ +mod client_report; +mod report; + +use std::path::PathBuf; + +use clap::{Parser, Subcommand}; +use client_report::create_client_report; + +#[derive(Parser, Debug)] +#[clap(author, version)] +struct Cli { + #[clap(subcommand)] + command: Commands, +} + +#[derive(Subcommand, Debug)] +enum Commands { + TestClient { + #[clap(value_parser)] + executable: PathBuf, + }, +} + +fn main() -> miette::Result<()> { + let args = Cli::parse(); + + match args.command { + Commands::TestClient { executable } => { + let report = create_client_report(executable)?; + } + } + + Ok(()) +} |