more fixes for tests
This commit is contained in:
1 parent
2558f722fc
commit
88616124b6
4 files changed
+60
-9
No files matched your search
@@ -49,7 +49,10 @@ final class PhoneWatchBridge: NSObject, WCSessionDelegate {
|
||||
private var deliveredVoiceTransferIDs: Set<String> = []
|
||||
|
||||
override init() {
|
||||
session = WCSession.isSupported() ? .default : nil
|
||||
session =
|
||||
!RuntimeEnvironment.isRunningTests && WCSession.isSupported()
|
||||
? .default
|
||||
: nil
|
||||
super.init()
|
||||
pendingVoiceMessages = Self.loadPersistedVoiceMessages()
|
||||
session?.delegate = self
|
||||
@@ -150,6 +153,7 @@ final class PhoneWatchBridge: NSObject, WCSessionDelegate {
|
||||
func sessionDidBecomeInactive(_ session: WCSession) {}
|
||||
|
||||
func sessionDidDeactivate(_ session: WCSession) {
|
||||
guard !RuntimeEnvironment.isRunningTests else { return }
|
||||
session.activate()
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user