diff --git a/tests/check_test_results.sh b/tests/check_test_results.sh new file mode 100755 index 00000000..e60cffe4 --- /dev/null +++ b/tests/check_test_results.sh @@ -0,0 +1,35 @@ +#!/bin/bash +# Simple test result checker +# Usage: ./tests/check_test_results.sh [logfile] + +LOGFILE=${1:-/tmp/test-param-fix-final.log} + +if [ ! -f "$LOGFILE" ]; then + echo "Log file not found: $LOGFILE" + exit 1 +fi + +# Check if tests are complete +if grep -q "Test Results Summary" "$LOGFILE"; then + echo "=========================================" + echo "Test Results" + echo "=========================================" + echo "" + + # Show summary + grep -A 30 "Test Results Summary" "$LOGFILE" | head -40 + + echo "" + echo "=========================================" + + # Count passed/failed + PASSED=$(grep -c "✅.*PASSED" "$LOGFILE") + FAILED=$(grep -c "❌.*FAILED" "$LOGFILE") + + echo "Environments: Passed=$PASSED, Failed=$FAILED" + +else + echo "Tests still running..." + echo "Last 10 lines:" + tail -10 "$LOGFILE" +fi diff --git a/tests/glob/test_installed_api_enabled_priority.py b/tests/glob/test_installed_api_enabled_priority.py index ff8c3097..7b9ed2e7 100644 --- a/tests/glob/test_installed_api_enabled_priority.py +++ b/tests/glob/test_installed_api_enabled_priority.py @@ -204,7 +204,7 @@ def test_installed_api_shows_disabled_when_no_enabled_exists( response = api_client.queue_task( kind="disable", ui_id="test_disabled_only_disable", - params={"id": TEST_PACKAGE_ID}, + params={"node_name": TEST_PACKAGE_ID}, ) assert response.status_code == 200 @@ -246,6 +246,17 @@ def test_installed_api_shows_disabled_when_no_enabled_exists( f"Package should be disabled, got: {package_info}" ) + # Cleanup: Re-enable package for other tests + response = api_client.queue_task( + kind="enable", + ui_id="test_disabled_only_cleanup", + params={"cnr_id": TEST_PACKAGE_ID}, + ) + assert response.status_code == 200 + response = api_client.start_queue() + assert response.status_code in [200, 201] + time.sleep(WAIT_TIME_SHORT) + def test_installed_api_no_duplicates_across_scenarios( api_client, @@ -306,7 +317,7 @@ def test_installed_api_no_duplicates_across_scenarios( response = api_client.queue_task( kind="disable", ui_id=f"test_{scenario_id}_disable", - params={"id": TEST_PACKAGE_ID}, + params={"node_name": TEST_PACKAGE_ID}, ) assert response.status_code == 200 response = api_client.start_queue() @@ -415,7 +426,7 @@ def test_installed_api_cnr_priority_when_both_disabled( response = api_client.queue_task( kind="disable", ui_id="test_cnr_priority_nightly_disable", - params={"id": TEST_PACKAGE_ID}, + params={"node_name": TEST_PACKAGE_ID}, ) assert response.status_code == 200 response = api_client.start_queue()