Skip to content

Commit

Permalink
Updated for Xcode 11 beta 4
Browse files Browse the repository at this point in the history
  • Loading branch information
tcldr committed Jul 17, 2019
1 parent 820b528 commit 78c8007
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
3 changes: 3 additions & 0 deletions Sources/Entwine/Operators/WithLatestFrom.swift
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,7 @@ extension Publishers {
}

func receive(completion: Subscribers.Completion<Downstream.Failure>) {
terminateSubscription()
_ = queue.enqueue(completion: completion)
}

Expand All @@ -124,6 +125,7 @@ extension Publishers {
func terminateSubscription() {
otherSink.terminateSubscription()
upstreamSubscription?.cancel()
upstreamSubscription = nil
}
}

Expand Down Expand Up @@ -160,6 +162,7 @@ extension Publishers {

func terminateSubscription() {
subscription?.cancel()
subscription = nil
}
}
}
Expand Down
4 changes: 2 additions & 2 deletions Tests/EntwineTests/MaterializeTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ final class MaterializeTests: XCTestCase {

func testMaterializesEmpty() {

let results1 = scheduler.start { Publishers.Empty<Int, Never>().materialize() }
let results1 = scheduler.start { Empty<Int, Never>().materialize() }

let expected1: TestSequence<Signal<Int, Never>, Never> = [
(200, .subscription),
Expand All @@ -60,7 +60,7 @@ final class MaterializeTests: XCTestCase {

enum MaterializedError: Error { case error }

let results1 = scheduler.start { Publishers.Fail<Int, MaterializedError>(error: .error).materialize() }
let results1 = scheduler.start { Fail<Int, MaterializedError>(error: .error).materialize() }

let expected1: TestSequence<Signal<Int, MaterializedError>, Never> = [
(200, .subscription),
Expand Down

0 comments on commit 78c8007

Please sign in to comment.