diff --git a/.github/workflows/replication-test.yml b/.github/workflows/replication-test.yml index 3ffa99e..597e272 100644 --- a/.github/workflows/replication-test.yml +++ b/.github/workflows/replication-test.yml @@ -112,7 +112,7 @@ jobs: if [ "${{ matrix.source }}" = "postgres" ]; then SOURCE_DSN="postgres://postgres:postgres@host.docker.internal:5432/test" else - SOURCE_DSN="mysql://root:root@host.docker.internal:3306/test?skip-tables=skip" + SOURCE_DSN="mysql://root:root@host.docker.internal:3306/test?skip-tables=test.skip" fi docker run -d --name myduck \ @@ -174,6 +174,19 @@ jobs: exit 1 fi + # Verify skipped table is empty (for MySQL-compatible databases only) + if [ "${{ matrix.source }}" != "postgres" ]; then + # Check if skip table has any rows + COUNT=$(docker exec myduck psql -t -U postgres -h 127.0.0.1 -c \ + "SELECT COUNT(*) FROM ${SCHEMA}.skip;" | tr -d ' ') + if [ "$COUNT" -eq "0" ]; then + echo "Successfully verified that skipped table exists but is empty" + else + echo "Error: Skipped table 'skip' contains $COUNT rows when it should be empty" + exit 1 + fi + fi + - name: Test replication of new data run: | # Insert new data in source