Skip to content

Commit 10e9172

Browse files
authored
This commit addresses configuration inconsistencies between CI/CD pipeline (#56)
and TestContainers setup that would prevent PostgreSQL integration tests from running correctly when re-enabled. ## Changes Made ### 1. Fixed Flyway Migration Paths - Files: application-testcontainers-postgresql.yml (datacustodian & thirdparty) - Before: classpath:db/migration/postgresql (non-existent path) - After: classpath:db/migration,classpath:db/vendor/postgres - Impact: Integration tests can now find and execute Flyway migrations ### 2. Upgraded PostgreSQL Version in CI/CD - File: .github/workflows/ci.yml - Before: postgres:15 - After: postgres:18 - Impact: Aligns CI/CD with TestContainers environment ### 3. Updated Test Documentation - File: DataCustodianApplicationPostgresTest.java - Updated @disabled annotation to reflect: - Configuration issues (Issue #55) are now RESOLVED - UUID type mismatch (Issue #53) still blocks test execution - Tests will be re-enabled after MULTI_PHASE schema compliance plan ## Test Results Verified that fixing Issue #55 configuration problems does NOT resolve Issue #53 UUID type mismatch. The test still fails with: Schema validation: wrong column type encountered in column [id]; found [bpchar (Types#CHAR)], but expecting [uuid (Types#UUID)] This confirms Issue #53 requires V4 migration script to convert CHAR(36) columns to native UUID type, which will be implemented after MULTI_PHASE schema compliance plan completes. ## Related Issues - Fixes #55 - PostgreSQL configuration mismatches - Ref #53 - UUID CHAR(36) type mismatch (still blocking) 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Sonnet 4.5 <[email protected]>"
1 parent 0fda4a2 commit 10e9172

File tree

4 files changed

+8
-6
lines changed

4 files changed

+8
-6
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ jobs:
3030
--health-retries=3
3131
3232
postgres:
33-
image: postgres:15
33+
image: postgres:18
3434
env:
3535
POSTGRES_PASSWORD: postgres
3636
POSTGRES_DB: test_db

openespi-common/src/test/java/org/greenbuttonalliance/espi/common/migration/DataCustodianApplicationPostgresTest.java

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,9 +27,9 @@
2727
import org.springframework.test.context.ActiveProfiles;
2828
import org.springframework.test.context.DynamicPropertyRegistry;
2929
import org.springframework.test.context.DynamicPropertySource;
30-
import org.testcontainers.postgresql.PostgreSQLContainer;
3130
import org.testcontainers.junit.jupiter.Container;
3231
import org.testcontainers.junit.jupiter.Testcontainers;
32+
import org.testcontainers.postgresql.PostgreSQLContainer;
3333

3434
import java.sql.Connection;
3535
import java.sql.ResultSet;
@@ -52,8 +52,10 @@
5252
@Disabled("Temporarily disabled due to Issue #53: PostgreSQL UUID CHAR(36) type mismatch. " +
5353
"JPA entities use @GeneratedValue(strategy = GenerationType.UUID) expecting native UUID type, " +
5454
"but Flyway migrations use CHAR(36) for MySQL/H2 compatibility. " +
55-
"This will be resolved after MULTI_PHASE schema compliance plan completes. " +
56-
"See: https://github.com/GreenButtonAlliance/OpenESPI-GreenButton-Java/issues/53")
55+
"Configuration issues (Issue #55) have been resolved - Flyway paths and PostgreSQL version are correct. " +
56+
"This test will be re-enabled after MULTI_PHASE schema compliance plan completes and UUID conversion is implemented. " +
57+
"See: https://github.com/GreenButtonAlliance/OpenESPI-GreenButton-Java/issues/53 " +
58+
"and https://github.com/GreenButtonAlliance/OpenESPI-GreenButton-Java/issues/55")
5759
class DataCustodianApplicationPostgresTest {
5860

5961
@Container

openespi-datacustodian/src/test/resources/application-testcontainers-postgresql.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ spring:
2626
flyway:
2727
enabled: true
2828
baseline-on-migrate: true
29-
locations: classpath:db/migration/postgresql
29+
locations: classpath:db/migration,classpath:db/vendor/postgres
3030

3131
# Faster testing configuration
3232
main:

openespi-thirdparty/src/test/resources/application-testcontainers-postgresql.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ spring:
2626
flyway:
2727
enabled: true
2828
baseline-on-migrate: true
29-
locations: classpath:db/migration/postgresql
29+
locations: classpath:db/migration,classpath:db/vendor/postgres
3030

3131
# Faster testing configuration
3232
main:

0 commit comments

Comments
 (0)