Integration tests
This commit is contained in:
5
.github/workflows/integration-tests.yml
vendored
5
.github/workflows/integration-tests.yml
vendored
@@ -84,7 +84,8 @@ jobs:
|
|||||||
RELSPEC_TEST_PG_CONN: postgres://relspec:relspec_test_password@localhost:5439/relspec_test
|
RELSPEC_TEST_PG_CONN: postgres://relspec:relspec_test_password@localhost:5439/relspec_test
|
||||||
run: |
|
run: |
|
||||||
echo "Testing connection using Go (same as integration tests will use)..."
|
echo "Testing connection using Go (same as integration tests will use)..."
|
||||||
cat > /tmp/test_conn.go << 'EOF'
|
mkdir -p /tmp/testconn
|
||||||
|
cat > /tmp/testconn/test_conn.go << 'EOF'
|
||||||
package main
|
package main
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
@@ -108,7 +109,7 @@ jobs:
|
|||||||
fmt.Printf("SUCCESS! Connected to: %s\n", version)
|
fmt.Printf("SUCCESS! Connected to: %s\n", version)
|
||||||
}
|
}
|
||||||
EOF
|
EOF
|
||||||
cd /tmp && go mod init testconn && go get github.com/jackc/pgx/v5 && go run test_conn.go
|
cd /tmp/testconn && go mod init testconn && go mod tidy && go run test_conn.go
|
||||||
|
|
||||||
- name: Run integration tests
|
- name: Run integration tests
|
||||||
env:
|
env:
|
||||||
|
|||||||
Reference in New Issue
Block a user