Updated variable
All checks were successful
Rust Build / Check (pull_request) Successful in 1m0s
Rust Build / Test Suite (pull_request) Successful in 1m2s
Rust Build / Rustfmt (pull_request) Successful in 31s
Rust Build / Clippy (pull_request) Successful in 47s
Rust Build / build (pull_request) Successful in 1m8s

This commit is contained in:
KD
2025-04-03 12:12:21 -04:00
parent e769d98d78
commit 34d72e7936

View File

@@ -70,8 +70,8 @@ jobs:
# --- Optional but Recommended: Database Migrations Step --- # --- Optional but Recommended: Database Migrations Step ---
- name: Run Database Migrations - name: Run Database Migrations
env: env:
# Define DATABASE_URL using service details and secrets # Define TEST_DATABASE_URL using service details and secrets
DATABASE_URL: postgresql://${{ secrets.DB_TEST_USER || 'testuser' }}:${{ secrets.DB_TEST_PASSWORD || 'testpassword' }}@postgres:5432/${{ secrets.DB_TEST_NAME || 'testdb' }} TEST_DATABASE_URL: postgresql://${{ secrets.DB_TEST_USER || 'testuser' }}:${{ secrets.DB_TEST_PASSWORD || 'testpassword' }}@postgres:5432/${{ secrets.DB_TEST_NAME || 'testdb' }}
# Make SSH agent available if migrations fetch private dependencies # Make SSH agent available if migrations fetch private dependencies
SSH_AUTH_SOCK: ${{ env.SSH_AUTH_SOCK }} SSH_AUTH_SOCK: ${{ env.SSH_AUTH_SOCK }}
run: | run: |
@@ -79,18 +79,18 @@ jobs:
# ===> IMPORTANT: Replace placeholder below with your actual migration command <=== # ===> IMPORTANT: Replace placeholder below with your actual migration command <===
# Example: Install and run sqlx-cli # Example: Install and run sqlx-cli
# cargo install sqlx-cli --no-default-features --features native-tls,postgres # cargo install sqlx-cli --no-default-features --features native-tls,postgres
# sqlx database setup --database-url $DATABASE_URL # sqlx database setup --database-url $TEST_DATABASE_URL
# Example: Install and run diesel_cli # Example: Install and run diesel_cli
# cargo install diesel_cli --no-default-features --features postgres # cargo install diesel_cli --no-default-features --features postgres
# diesel migration run --database-url $DATABASE_URL # diesel migration run --database-url $TEST_DATABASE_URL
# echo "[Placeholder] Your migration command goes here." # echo "[Placeholder] Your migration command goes here."
# ===> End of Placeholder <=== # ===> End of Placeholder <===
- name: Run tests - name: Run tests
env: env:
# Define DATABASE_URL for tests to use # Define TEST_DATABASE_URL for tests to use
DATABASE_URL: postgresql://${{ secrets.DB_TEST_USER || 'testuser' }}:${{ secrets.DB_TEST_PASSWORD || 'testpassword' }}@postgres:5432/${{ secrets.DB_TEST_NAME || 'testdb' }} TEST_DATABASE_URL: postgresql://${{ secrets.DB_TEST_USER || 'testuser' }}:${{ secrets.DB_TEST_PASSWORD || 'testpassword' }}@postgres:5432/${{ secrets.DB_TEST_NAME || 'testdb' }}
RUST_LOG: info # Optional: configure test log level RUST_LOG: info # Optional: configure test log level
# Make SSH agent available if tests fetch private dependencies # Make SSH agent available if tests fetch private dependencies
SSH_AUTH_SOCK: ${{ env.SSH_AUTH_SOCK }} SSH_AUTH_SOCK: ${{ env.SSH_AUTH_SOCK }}