|
@@ -22,7 +22,7 @@ cleanup() {
|
|
|
# Remove the temporary directory
|
|
# Remove the temporary directory
|
|
|
rm -rf "$CDK_ITESTS_DIR"
|
|
rm -rf "$CDK_ITESTS_DIR"
|
|
|
echo "Temp directory removed: $CDK_ITESTS_DIR"
|
|
echo "Temp directory removed: $CDK_ITESTS_DIR"
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
# Unset all environment variables that were set
|
|
# Unset all environment variables that were set
|
|
|
unset CDK_ITESTS_DIR
|
|
unset CDK_ITESTS_DIR
|
|
|
unset CDK_ITESTS_MINT_ADDR
|
|
unset CDK_ITESTS_MINT_ADDR
|
|
@@ -74,7 +74,7 @@ fi
|
|
|
echo "Temp directory created: $CDK_ITESTS_DIR"
|
|
echo "Temp directory created: $CDK_ITESTS_DIR"
|
|
|
export MINT_DATABASE="$1";
|
|
export MINT_DATABASE="$1";
|
|
|
|
|
|
|
|
-cargo build -p cdk-integration-tests
|
|
|
|
|
|
|
+cargo build -p cdk-integration-tests
|
|
|
|
|
|
|
|
|
|
|
|
|
export CDK_TEST_REGTEST=0
|
|
export CDK_TEST_REGTEST=0
|
|
@@ -125,7 +125,7 @@ echo "$CDK_PAYMENT_PROCESSOR_CLN_RPC_PATH"
|
|
|
|
|
|
|
|
cargo b --bin cdk-payment-processor
|
|
cargo b --bin cdk-payment-processor
|
|
|
|
|
|
|
|
-cargo run --bin cdk-payment-processor &
|
|
|
|
|
|
|
+cargo run --bin cdk-payment-processor -- --enable-logging --log-level=info &
|
|
|
|
|
|
|
|
CDK_PAYMENT_PROCESSOR_PID=$!
|
|
CDK_PAYMENT_PROCESSOR_PID=$!
|
|
|
|
|
|
|
@@ -140,10 +140,10 @@ export CDK_MINTD_GRPC_PAYMENT_PROCESSOR_PORT="8090";
|
|
|
export CDK_MINTD_LOGGING_CONSOLE_LEVEL="debug"
|
|
export CDK_MINTD_LOGGING_CONSOLE_LEVEL="debug"
|
|
|
export CDK_MINTD_GRPC_PAYMENT_PROCESSOR_SUPPORTED_UNITS="sat";
|
|
export CDK_MINTD_GRPC_PAYMENT_PROCESSOR_SUPPORTED_UNITS="sat";
|
|
|
export CDK_MINTD_MNEMONIC="eye survey guilt napkin crystal cup whisper salt luggage manage unveil loyal";
|
|
export CDK_MINTD_MNEMONIC="eye survey guilt napkin crystal cup whisper salt luggage manage unveil loyal";
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
cargo build --bin cdk-mintd --no-default-features --features grpc-processor
|
|
cargo build --bin cdk-mintd --no-default-features --features grpc-processor
|
|
|
|
|
|
|
|
-cargo run --bin cdk-mintd --no-default-features --features grpc-processor &
|
|
|
|
|
|
|
+cargo run --bin cdk-mintd --no-default-features --features grpc-processor -- --enable-logging &
|
|
|
CDK_MINTD_PID=$!
|
|
CDK_MINTD_PID=$!
|
|
|
|
|
|
|
|
echo $CDK_ITESTS_DIR
|
|
echo $CDK_ITESTS_DIR
|
|
@@ -154,7 +154,7 @@ START_TIME=$(date +%s)
|
|
|
while true; do
|
|
while true; do
|
|
|
# Get the current time
|
|
# Get the current time
|
|
|
CURRENT_TIME=$(date +%s)
|
|
CURRENT_TIME=$(date +%s)
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
# Calculate the elapsed time
|
|
# Calculate the elapsed time
|
|
|
ELAPSED_TIME=$((CURRENT_TIME - START_TIME))
|
|
ELAPSED_TIME=$((CURRENT_TIME - START_TIME))
|
|
|
|
|
|
|
@@ -187,7 +187,7 @@ if [ "$LN_BACKEND" = "CLN" ]; then
|
|
|
echo "Running bolt12 tests for CLN backend"
|
|
echo "Running bolt12 tests for CLN backend"
|
|
|
RUST_LOG=info cargo test -p cdk-integration-tests --test bolt12
|
|
RUST_LOG=info cargo test -p cdk-integration-tests --test bolt12
|
|
|
bolt12_test_status=$?
|
|
bolt12_test_status=$?
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
# Exit with non-zero status if either test failed
|
|
# Exit with non-zero status if either test failed
|
|
|
if [ $test_status -ne 0 ] || [ $bolt12_test_status -ne 0 ]; then
|
|
if [ $test_status -ne 0 ] || [ $bolt12_test_status -ne 0 ]; then
|
|
|
echo "Tests failed - happy_path_mint_wallet: $test_status, bolt12: $bolt12_test_status"
|
|
echo "Tests failed - happy_path_mint_wallet: $test_status, bolt12: $bolt12_test_status"
|