-
Notifications
You must be signed in to change notification settings - Fork 841
Debug test failures #3654
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Debug test failures #3654
Conversation
- Standardize PostgreSQL commands with `-h localhost` for clarity. - Improve robustness in scripts: add checks for file writability and existence. - Adjust Gradle logging for better visibility and lifecycle tracking. - Minor enhancements to integration and helper scripts for better error handling and output tracing.
- Removed jacocoCargoReport task from `build.gradle`. - Updated SonarQube Gradle plugin to version 7.0.1.6134
4248e60 to
78e0174
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR focuses on improving robustness and maintainability of the UAA build and test infrastructure. The changes include upgrading dependencies, adding debug logging, improving error handling in shell scripts, and removing unused code.
Key changes:
- Upgraded sonarqube plugin from version 6.3.1.5724 to 7.0.1.6134
- Enhanced shell script error handling with file existence checks and graceful fallbacks
- Added debug logging via
set -xin docker database startup script - Removed test logging configuration block and unused Jacoco cargo report task from Gradle build files
- Removed entire boot integration tests workflow file
Reviewed Changes
Copilot reviewed 8 out of 9 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| uaa/build.gradle | Removed testLogging block and added lifecycle logging for UAA auto-start/stop events |
| scripts/start_docker_database.sh | Added debug mode (set -x) to trace docker commands |
| scripts/lib_util_helper.sh | Added file writability/existence checks before accessing /etc/hosts and /proc/meminfo; removed -q flag from grep |
| scripts/lib_ldap_helper.sh | Changed LDAP setup detection failure from exit to graceful skip |
| scripts/lib_db_helper.sh | Added -h localhost flag to all PostgreSQL psql commands and reformatted multi-line init_db command |
| scripts/integration_tests.sh | Added default value hsqldb for DB variable |
| dependencies.gradle | Upgraded sonarqube-gradle-plugin from 6.3.1.5724 to 7.0.1.6134 |
| build.gradle | Removed unused imports and jacocoCargoReport task definition |
| .github/workflows/boot-integration-tests.yml | Deleted entire workflow file |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
scripts/lib_db_helper.sh
Outdated
| init_db="psql -c 'drop database if exists uaa;' -h localhost -U postgres | ||
| psql -c 'create database uaa;' -h localhost -U postgres; | ||
| psql -c 'drop user if exists root;' -h localhost --dbname=uaa -U postgres; | ||
| psql -c \"create user root with superuser password '${db_password}';\" -h localhost --dbname=uaa -U postgres; | ||
| psql -c 'show max_connections;' -h localhost --dbname=uaa -U postgres;" |
Copilot
AI
Oct 28, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The multi-line command string is missing semicolons at the end of line 123. Since this is assigned to a variable and later executed with eval, the first command will fail. Line 123 should end with a semicolon: 'drop database if exists uaa;' -h localhost -U postgres;
We've had a lot of failures in workflows recently.
-h localhostfor clarity.