Skip to content

Commit

Permalink
Update the check command help to refer to the Hybrid Integration Test…
Browse files Browse the repository at this point in the history
…ing Tool section in the README for sample input instructions
  • Loading branch information
rsachdeva committed Sep 25, 2024
1 parent 8fe6221 commit 914c69d
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 15 deletions.
9 changes: 6 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -313,9 +313,12 @@ Key features:
* Sends calculations to EventBridge for comprehensive sanity testing
* Validates event routing to appropriate destinations (log groups, AWS Lambda functions, DynamoDB)
* Allows developers to verify end-to-end flow of calculations, event handling, and data persistence
Execute the tool with:
`just run-drive-deposits-check-cmd-valid-send-events`
This streamlined approach significantly enhances development efficiency and system reliability testing.

Execute the tool with:

`just run-drive-deposits-check-cmd-valid-send-events`

This streamlined approach significantly enhances development efficiency and system reliability testing.

###### Alias

Expand Down
14 changes: 2 additions & 12 deletions drive-deposits-check-cmd/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,26 +12,16 @@ use drive_deposits_check_cmd::portfolio::calculate::process_input;
/// The data types used in this command are consistent with those in the actual services, ensuring a dependable method for rapid local verification of calculations.
/// Use this command to verify calculations locally.
///
/// ### Sample Commands
/// Run the following commands through Cargo or directly with the binary:
///
/// - To check the version: `cargo run -- --version`
///
/// - For help: `cargo run -- --help`
///
/// - To run with a sample input file: `cargo run -- tests/data/input.json`
/// To run with a sample input file: see the "Hybrid Integration Testing Tool" section in the README.md file.
///
struct Args {
/// Input text
/// Input json file path
#[arg(required(true))]
json_request_file_path: String,
}

#[tokio::main]
async fn main() -> Result<()> {
let rust_log = std::env::var("RUST_LOG")?;
println!("in drive-deposits-check-cmd RUST_LOG is {}", rust_log);

registry()
.with(EnvFilter::try_from_default_env()?)
// added in .cargo/config.tom .add_directive("drive_deposits_local=debug".parse()?))
Expand Down
3 changes: 3 additions & 0 deletions justfile
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,9 @@ watch-build-drive-deposits-grpc-server:
run-drive-deposits-check-cmd-valid:
SEND_CAL_EVENTS="false" cargo ddcheck -- drive-deposits-rest-gateway-server/data/portfolio_request_valid.json

run-drive-deposits-check-cmd-help:
SEND_CAL_EVENTS="true" cargo ddcheck -- --help

run-drive-deposits-check-cmd-valid-send-events:
SEND_CAL_EVENTS="true" cargo ddcheck -- drive-deposits-rest-gateway-server/data/portfolio_request_valid.json

Expand Down

0 comments on commit 914c69d

Please sign in to comment.