diff --git a/wayang-platforms/wayang-jdbc-template/src/test/java/org/apache/wayang/jdbc/operators/JdbcJoinOperatorTest.java b/wayang-platforms/wayang-jdbc-template/src/test/java/org/apache/wayang/jdbc/operators/JdbcJoinOperatorTest.java index ab984a751..875a7a47b 100644 --- a/wayang-platforms/wayang-jdbc-template/src/test/java/org/apache/wayang/jdbc/operators/JdbcJoinOperatorTest.java +++ b/wayang-platforms/wayang-jdbc-template/src/test/java/org/apache/wayang/jdbc/operators/JdbcJoinOperatorTest.java @@ -33,6 +33,7 @@ import org.apache.wayang.jdbc.execution.JdbcExecutor; import org.apache.wayang.core.profiling.NoInstrumentationStrategy; import org.apache.wayang.core.optimizer.DefaultOptimizationContext; +import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; import java.sql.Connection; @@ -48,6 +49,21 @@ * Test suite for {@link SqlToStreamOperator}. */ class JdbcJoinOperatorTest extends OperatorTestBase { + @BeforeEach + void initDB() throws SQLException { + HsqldbPlatform hsqldbPlatform = new HsqldbPlatform(); + try ( + Connection jdbcConnection = hsqldbPlatform + .createDatabaseDescriptor(configuration) + .createJdbcConnection() + ) { + final Statement statement = jdbcConnection.createStatement(); + statement.execute("DROP TABLE IF EXISTS testA"); + statement.execute("DROP TABLE IF EXISTS testB"); + statement.execute("DROP TABLE IF EXISTS orders"); + statement.execute("DROP TABLE IF EXISTS shipments"); + } + } @Test void testWithHsqldb() throws SQLException { Configuration configuration = new Configuration();