Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
84 commits
Select commit Hold shift + click to select a range
5facc7c
add changes in sub module
Falconwu17 Feb 20, 2026
fe74601
add debug for check all params
Falconwu17 Feb 24, 2026
7ef3da5
modified run bruno
Falconwu17 Feb 24, 2026
aa034bb
changes params vars
Falconwu17 Feb 24, 2026
873a3ff
update upr case in lower case
Falconwu17 Feb 24, 2026
6eea4c3
update export for env
Falconwu17 Feb 24, 2026
7a6760d
update scripts
Falconwu17 Feb 24, 2026
8a7b219
feat: add allure
Falconwu17 Feb 24, 2026
e96fabf
fix: add allure in bruno
Falconwu17 Feb 24, 2026
1b17dc8
update for run all clc
Falconwu17 Feb 25, 2026
7ff4820
add debug
Falconwu17 Feb 26, 2026
722c796
fix: runner add allure env
Falconwu17 Feb 26, 2026
9969e8c
fix: bruno clc
Falconwu17 Feb 26, 2026
84505a4
feat: push release version
Falconwu17 Feb 26, 2026
5f1d5f1
feat: add debug
Falconwu17 Feb 27, 2026
f035105
fix: upd check this method
Falconwu17 Feb 27, 2026
aa793b3
fix: test_runner.sh BRU_BIN
Falconwu17 Feb 27, 2026
b1a5d76
feat: add env in allure results
Falconwu17 Mar 2, 2026
bcfe091
fix: upload-monitor.sh
Falconwu17 Mar 2, 2026
df93799
fix: updates for env
Falconwu17 Mar 2, 2026
9b15c48
fix test runner sh
Falconwu17 Mar 2, 2026
a2a1855
fix: add allure results
Falconwu17 Mar 2, 2026
d318f8f
fix: add allure report in upload-monitor.sh
Falconwu17 Mar 3, 2026
ac87ee4
fix: allure-results in generate-email
Falconwu17 Mar 3, 2026
478777b
fix: shelchek
Falconwu17 Mar 3, 2026
3f13fcc
feat: add debug
Falconwu17 Mar 3, 2026
9c295c7
fix: add debug
Falconwu17 Mar 3, 2026
952bc0f
fix: add echo report view
Falconwu17 Mar 3, 2026
f991cff
fix: update email notification deleted export and fix printf
Falconwu17 Mar 3, 2026
64cbacb
shellcheck
Falconwu17 Mar 3, 2026
0dfcb75
feat: add pararell
Falconwu17 Mar 5, 2026
161672d
fix: del pararell run and fix problem in JSON
Falconwu17 Mar 6, 2026
0727c6b
feat: add folder in TEST PARMAS and fix upload-monitor.sh
Falconwu17 Mar 11, 2026
91c4c86
fix: del --folder and start folder
Falconwu17 Mar 11, 2026
acfbcf6
fix: folder search
Falconwu17 Mar 11, 2026
c710904
fix: folder and found
Falconwu17 Mar 11, 2026
d3eca42
feat: check add pararell for xargs
Falconwu17 Mar 12, 2026
d9694de
feat: add full debug in allure results
Falconwu17 Mar 12, 2026
b58dbb8
fix: add debug and fix folder select
Falconwu17 Mar 13, 2026
0c18a0d
fix: folder
Falconwu17 Mar 13, 2026
677492d
fix allure results
Falconwu17 Mar 16, 2026
c2a5130
feat: add if submodule
Falconwu17 Mar 17, 2026
62049ca
fix: submodule
Falconwu17 Mar 18, 2026
de22342
feat: add serverhostname
Falconwu17 Mar 19, 2026
a9c6f25
fix: add debug
Falconwu17 Mar 20, 2026
4f6cdcb
fix: jq parse erorr
Falconwu17 Mar 30, 2026
afe963a
fix: allure report fix
Falconwu17 Mar 30, 2026
8e3bb44
feat: add debug in test_runner
Falconwu17 Mar 31, 2026
f039d9a
feat: add new debug in tets_runner
Falconwu17 Mar 31, 2026
dd9fd4f
ATPIII-1 upd vrs
Falconwu17 Mar 31, 2026
4bbb44c
fix: delete logs bruno
Falconwu17 Mar 31, 2026
c8da24d
fix: upload monitor
Falconwu17 Mar 31, 2026
a22ab0a
fix: update xargs
Falconwu17 Mar 31, 2026
11a61eb
feat: check this update
Falconwu17 Apr 1, 2026
cd8ecd0
fix: add debug
Falconwu17 Apr 1, 2026
06753ce
feat: delete super linter warning
Falconwu17 Apr 1, 2026
3d9197d
fix: optimizated sync
Falconwu17 Apr 1, 2026
ebd0787
fix: delete xargs
Falconwu17 Apr 1, 2026
f505e71
fix: pararel 2
Falconwu17 Apr 1, 2026
c77c526
feat: add new logic for test
Falconwu17 Apr 2, 2026
e84ff8d
fix: deleted new logic
Falconwu17 Apr 2, 2026
28bd53e
feat: merge conflict deleted
Falconwu17 Apr 3, 2026
7060e34
feat: merge conflicts deleted
Falconwu17 Apr 3, 2026
b6cb246
feat: add run full clc
Falconwu17 Apr 6, 2026
fd93146
feat: one env for all clc
Falconwu17 Apr 8, 2026
4c7cd32
feat: add universal envgene download
Falconwu17 Apr 10, 2026
a4333a1
feat: add debug
Falconwu17 Apr 13, 2026
fed7170
feat: add env for one clc
Falconwu17 Apr 14, 2026
79b7c8a
feat: source check
Falconwu17 Apr 15, 2026
03b4699
feat: add new logic patch in scripts
Falconwu17 Apr 15, 2026
cc98dbf
fix: dir patch
Falconwu17 Apr 15, 2026
ccd3359
fix :del patch func
Falconwu17 Apr 15, 2026
297983e
feat: add auto killer clc
Falconwu17 Apr 17, 2026
e0d4849
fix: map file
Falconwu17 Apr 17, 2026
9b3d948
feat: add full log
Falconwu17 Apr 20, 2026
7eb5bd5
fix: tools and sh scripts
Falconwu17 Apr 22, 2026
f17086e
fix: source
Falconwu17 Apr 22, 2026
dd16509
fix: source v2
Falconwu17 Apr 22, 2026
2ac84ae
fix: pid procces
Falconwu17 Apr 22, 2026
a451e2f
fix: uuid problems
Falconwu17 Apr 23, 2026
ab5f757
fix: folders logic
Falconwu17 Apr 23, 2026
c02ff85
fix: upload.sh check delete &
Falconwu17 Apr 23, 2026
78da16d
fix: &
Falconwu17 Apr 23, 2026
cd6eb06
fix: delete generate allure res
Falconwu17 Apr 24, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion email-notification/README-email-notification-json.md
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ echo "$json_content"

# Or use exported variables
echo "JSON file: $JSON_FILE"
echo "Content: $GENERATED_JSON"


# File will be saved to: ../email-notification-generated/email-notification-results-generated.json
```
Expand Down
18 changes: 10 additions & 8 deletions email-notification/calculate-email-notification-variables.sh
Original file line number Diff line number Diff line change
Expand Up @@ -19,15 +19,15 @@ log_info() {
log_success() {
echo "✅ $1"
}

# shellcheck disable=SC2329
log_warning() {
echo "⚠️ $1"
}

# shellcheck disable=SC2329
log_error() {
echo "❌ $1"
}

# shellcheck disable=SC2034
# Get script directory
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"

Expand Down Expand Up @@ -74,7 +74,8 @@ for result_file in "$ALLURE_RESULTS_DIR"/*-result.json; do
# Extract test status using jq
status=$(jq -r '.status' "$result_file" 2>/dev/null || echo "unknown")
test_name=$(jq -r '.name' "$result_file" 2>/dev/null || echo "Unknown Test")

test_name=$(printf '%s' "$test_name" | jq -R .)
test_name=${test_name:1:-1}
case "$status" in
"passed")
passed_tests=$((passed_tests + 1))
Expand Down Expand Up @@ -113,8 +114,10 @@ if [ "$BC_AVAILABLE" = true ]; then
pass_rate_rounded=$(echo "scale=0; $passed_tests * 100 / $total_tests" | bc)
else
# Use awk for calculations if bc is not available
pass_rate=$(awk "BEGIN {printf \"%.2f\", $passed_tests * 100 / $total_tests}")
pass_rate_rounded=$(awk "BEGIN {printf \"%.0f\", $passed_tests * 100 / $total_tests}")
pass_rate=$(awk -v p="$passed_tests" -v t="$total_tests" \
'BEGIN { if (t > 0) printf "%.2f", p * 100 / t; else print "0.00" }')
pass_rate_rounded=$(awk -v p="$passed_tests" -v t="$total_tests" \
'BEGIN { if (t > 0) printf "%.0f", p * 100 / t; else print "0" }')
fi

# Determine overall status
Expand All @@ -135,16 +138,15 @@ export TEST_FAILED_COUNT="$failed_tests"
export TEST_SKIPPED_COUNT="$skipped_tests"
export TEST_OVERALL_STATUS="$overall_status"

# Create test details string
TEST_DETAILS_STRING=""
# Create test details string
for test_detail in "${test_details[@]}"; do
if [ -n "$TEST_DETAILS_STRING" ]; then
TEST_DETAILS_STRING="$TEST_DETAILS_STRING\n$test_detail"
else
TEST_DETAILS_STRING="$test_detail"
fi
done
export TEST_DETAILS_STRING="$TEST_DETAILS_STRING"

# Display summary
echo ""
Expand Down
2 changes: 1 addition & 1 deletion email-notification/generate-email-notification-file.sh
Original file line number Diff line number Diff line change
Expand Up @@ -207,4 +207,4 @@ generate_email_notification_file() {

# Return the message content
# echo "$message_content"
}
}
26 changes: 17 additions & 9 deletions email-notification/generate-email-notification-json.sh
Original file line number Diff line number Diff line change
Expand Up @@ -22,17 +22,17 @@ generate_email_notification_json() {
log_success() {
echo "✅ $1"
}

# shellcheck disable=SC2329
log_warning() {
echo "⚠️ $1"
}

# shellcheck disable=SC2329
log_error() {
echo "❌ $1"
}

# Get script directory
local SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
local SCRIPT_DIR
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"

# Set allure results directory to default location
local allure_results_dir="/tmp/clone/allure-results"
Expand All @@ -50,7 +50,8 @@ generate_email_notification_json() {

# Calculate additional metrics
if [ -n "${TEST_TOTAL_COUNT:-}" ] && [ "$TEST_TOTAL_COUNT" -gt 0 ]; then
TEST_FAILURE_RATE=$(awk "BEGIN {printf \"%.2f\", $TEST_FAILED_COUNT * 100 / $TEST_TOTAL_COUNT}")
TEST_FAILURE_RATE=$(awk -v failed="$TEST_FAILED_COUNT" -v total="$TEST_TOTAL_COUNT" \
'BEGIN { if (total > 0) printf "%.2f", failed * 100 / total; else print "0.00" }')
else
TEST_FAILURE_RATE="0.00"
fi
Expand Down Expand Up @@ -82,6 +83,8 @@ generate_email_notification_json() {
local status_part="${BASH_REMATCH[1]// /}"
# Keep test name exactly as is (no formatting applied)
local test_name="${BASH_REMATCH[2]}"
test_name=$(printf '%s' "$test_name" | jq -R .)
test_name=${test_name:1:-1}


# Determine status and emoji
Expand Down Expand Up @@ -118,8 +121,12 @@ generate_email_notification_json() {
for result_file in "$allure_results_dir"/*-result.json; do
if [ -f "$result_file" ]; then
# Extract test status and name using jq
local status=$(jq -r '.status' "$result_file" 2>/dev/null || echo "unknown")
local test_name=$(jq -r '.name' "$result_file" 2>/dev/null || echo "Unknown Test")
local status
status=$(jq -r '.status' "$result_file" 2>/dev/null || echo "unknown")
local test_name
test_name=$(jq -r '.name' "$result_file" 2>/dev/null || echo "Unknown Test")
test_name=$(printf '%s' "$test_name" | jq -R .)
test_name=${test_name:1:-1}

# Determine status and emoji
local emoji="❓"
Expand Down Expand Up @@ -230,10 +237,11 @@ generate_email_notification_json() {


# Export the JSON content as environment variable for use in other scripts
export GENERATED_JSON="$json_content"
export JSON_FILE="$output_file"

log_info "Environment variables exported: GENERATED_JSON, JSON_FILE"
log_info "Environment variables exported: JSON_FILE"
echo "$output_file"
return 0

# Return the JSON content
# echo "$json_content"
Expand Down
72 changes: 72 additions & 0 deletions envgene.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
#!/usr/bin/env bash

load_envgene() {
if [ -z "${ATP_ENVGENE_CONFIGURATION:-}" ]; then
echo "ATP_ENVGENE_CONFIGURATION is empty, skipping EnvGene mapping"
return 0
fi

echo "Loading EnvGene configuration..."

to_env_name() {
printf '%s\n' "$1" \
| tr '[:lower:]' '[:upper:]' \
| sed 's/[^A-Z0-9]/_/g'
}

derive_namespace_and_hostname() {
local url="$1"
local host namespace_part

if [ -z "$url" ]; then
export NAMESPACE="unknown"
export SERVER_HOSTNAME="unknown"
return 0
fi

host=$(printf '%s\n' "$url" | sed -E 's#https?://([^/]+).*#\1#')

if [[ "$host" == public-gateway-*.* ]]; then
namespace_part="${host#public-gateway-}"
export NAMESPACE="${namespace_part%%.*}"

if [[ "$host" == public-gateway-"$NAMESPACE".* ]]; then
export SERVER_HOSTNAME="${host#public-gateway-$NAMESPACE.}"
else
export SERVER_HOSTNAME="$host"
fi
else
export NAMESPACE="unknown"
export SERVER_HOSTNAME="$host"
fi
}

while IFS=$'\t' read -r system_name field_name field_value; do
[ -z "$system_name" ] && continue
[ -z "$field_name" ] && continue
[ -z "$field_value" ] && continue

env_name="$(to_env_name "${system_name}_${field_name}")"
export "${env_name}=${field_value}"

echo " ${env_name}=${field_value}"
done < <(
jq -r '
.systems[]
| to_entries[]
| .key as $system_name
| .value.connections[0].HTTP? // empty
| to_entries[]
| select(.key == "url" or .key == "login" or .key == "password")
| select(.value != null and .value != "")
| [$system_name, .key, (.value | tostring)]
| @tsv
' <<< "$ATP_ENVGENE_CONFIGURATION"
)

derive_namespace_and_hostname "${PUBLIC_GATEWAY_URL:-}"

echo "Derived values:"
echo " NAMESPACE=${NAMESPACE}"
echo " SERVER_HOSTNAME=${SERVER_HOSTNAME}"
}
Loading
Loading