Skip to content

Commit cf29fe2

Browse files
committed
Fix tests
1 parent 9ddc706 commit cf29fe2

File tree

2 files changed

+12
-4
lines changed

2 files changed

+12
-4
lines changed

Sources/PowerSync/Kotlin/KotlinPowerSyncDatabaseImpl.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -89,10 +89,10 @@ final class KotlinPowerSyncDatabaseImpl: PowerSyncDatabaseProtocol,
8989
try await kotlinDatabase.disconnect()
9090
}
9191

92-
func disconnectAndClear(clearLocal: Bool = true) async throws {
92+
func disconnectAndClear(clearLocal: Bool, soft: Bool) async throws {
9393
try await kotlinDatabase.disconnectAndClear(
9494
clearLocal: clearLocal,
95-
soft: false
95+
soft: soft
9696
)
9797
}
9898

Sources/PowerSync/Protocol/PowerSyncDatabaseProtocol.swift

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -308,8 +308,16 @@ public extension PowerSyncDatabaseProtocol {
308308
)
309309
}
310310

311-
func disconnectAndClear(clearLocal: Bool = true, soft: Bool = false) async throws {
312-
try await disconnectAndClear(clearLocal: clearLocal, soft: soft)
311+
func disconnectAndClear() async throws {
312+
try await disconnectAndClear(clearLocal: true, soft: false)
313+
}
314+
315+
func disconnectAndClear(clearLocal: Bool) async throws {
316+
try await disconnectAndClear(clearLocal: clearLocal, soft: false)
317+
}
318+
319+
func disconnectAndClear(soft: Bool) async throws {
320+
try await disconnectAndClear(clearLocal: true, soft: soft)
313321
}
314322

315323
func getCrudBatch(limit: Int32 = 100) async throws -> CrudBatch? {

0 commit comments

Comments
 (0)