Fixed linting issues
This commit is contained in:
15
.github/workflows/integration-tests.yml
vendored
15
.github/workflows/integration-tests.yml
vendored
@@ -35,10 +35,10 @@ jobs:
|
||||
run: |
|
||||
docker run -d \
|
||||
--name relspec-test-postgres \
|
||||
--network host \
|
||||
-e POSTGRES_USER=relspec \
|
||||
-e POSTGRES_PASSWORD=relspec_test_password \
|
||||
-e POSTGRES_DB=relspec_test \
|
||||
-p 5432:5432 \
|
||||
postgres:16-alpine
|
||||
|
||||
- name: Wait for PostgreSQL to be ready
|
||||
@@ -54,23 +54,18 @@ jobs:
|
||||
done
|
||||
sleep 2
|
||||
|
||||
- name: Install PostgreSQL client
|
||||
- name: Copy init script into container
|
||||
run: |
|
||||
sudo apt-get update
|
||||
sudo apt-get install -y postgresql-client
|
||||
docker cp tests/postgres/init.sql relspec-test-postgres:/tmp/init.sql
|
||||
|
||||
- name: Initialize test database
|
||||
env:
|
||||
PGPASSWORD: relspec_test_password
|
||||
run: |
|
||||
psql -h localhost -U relspec -d relspec_test -f tests/postgres/init.sql
|
||||
docker exec relspec-test-postgres psql -U relspec -d relspec_test -f /tmp/init.sql
|
||||
|
||||
- name: Verify database setup
|
||||
env:
|
||||
PGPASSWORD: relspec_test_password
|
||||
run: |
|
||||
echo "Verifying database initialization..."
|
||||
psql -h localhost -U relspec -d relspec_test -c "
|
||||
docker exec relspec-test-postgres psql -U relspec -d relspec_test -c "
|
||||
SELECT
|
||||
(SELECT COUNT(*) FROM pg_namespace WHERE nspname NOT IN ('pg_catalog', 'information_schema', 'pg_toast') AND nspname NOT LIKE 'pg_%') as schemas,
|
||||
(SELECT COUNT(*) FROM pg_tables WHERE schemaname NOT IN ('pg_catalog', 'information_schema')) as tables,
|
||||
|
||||
Reference in New Issue
Block a user