File tree 2 files changed +9
-2
lines changed
kork-sql-test/src/main/java/com/netflix/spinnaker/kork/sql/test
2 files changed +9
-2
lines changed Original file line number Diff line number Diff line change @@ -265,7 +265,14 @@ public static void cleanupDb(DSLContext context) {
265
265
&& !table .getName ().equals (configuration .getDatabaseChangeLogLockTableName ()))
266
266
.forEach (
267
267
table -> {
268
- context .truncate (table .getName ()).execute ();
268
+ switch (context .dialect ()) {
269
+ case POSTGRES :
270
+ context .truncateTable (table .getName ()).cascade ().execute ();
271
+ break ;
272
+ default :
273
+ context .truncateTable (table .getName ()).execute ();
274
+ break ;
275
+ }
269
276
});
270
277
if (context .dialect () == SQLDialect .MYSQL ) {
271
278
context .execute ("set foreign_key_checks=1" );
Original file line number Diff line number Diff line change @@ -52,7 +52,7 @@ dependencies {
52
52
api(platform(" io.strikt:strikt-bom:0.28.0" ))
53
53
api(platform(" org.spockframework:spock-bom:1.3-groovy-2.5" ))
54
54
api(platform(" com.oracle.oci.sdk:oci-java-sdk-bom:1.5.17" ))
55
- api(platform(" org.testcontainers:testcontainers-bom:1.14.3 " ))
55
+ api(platform(" org.testcontainers:testcontainers-bom:1.15.0 " ))
56
56
api(platform(" com.google.protobuf:protobuf-bom:${ versions.protobuf} " ))
57
57
58
58
constraints {
You can’t perform that action at this time.
0 commit comments