Skip to content

Commit 998c080

Browse files
committed
Changed expectPublisher/expectTask to be expect
1 parent 34ab24f commit 998c080

File tree

4 files changed

+7
-7
lines changed

4 files changed

+7
-7
lines changed

WorkflowCombine/Testing/PublisherTesting.swift

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,17 +22,17 @@
2222
import XCTest
2323
@testable import WorkflowCombine
2424

25-
@available(macOS 10.15, *)
26-
@available(iOS 13.0, *)
27-
extension RenderTester {
25+
@available(macOS 10.15, *)
26+
@available(iOS 13.0, *)
27+
extension RenderTester {
2828
/// Expect a `Publisher`s.
2929
///
3030
/// `PublisherWorkflow` is used to subscribe to `Publisher`s.
3131
///
3232
/// - Parameters:
3333
/// - producingOutput: An output that should be returned when this worker is requested, if any.
3434
/// - key: Key to expect this `Workflow` to be rendered with.
35-
public func expectPublisher<PublisherType: Publisher>(
35+
public func expect<PublisherType: Publisher>(
3636
publisher: PublisherType.Type,
3737
output: PublisherType.Output,
3838
key: String = ""

WorkflowCombine/TestingTests/PublisherTests.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ class PublisherTests: XCTestCase {
1717
func testPublisherWorkflow() {
1818
TestWorkflow()
1919
.renderTester()
20-
.expectPublisher(publisher: Publishers.Sequence<[Int], Never>.self, output: 1, key: "123")
20+
.expect(publisher: Publishers.Sequence<[Int], Never>.self, output: 1, key: "123")
2121
.render {}
2222
}
2323

WorkflowConcurrency/Testing/TaskTesting.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232
/// - Parameters:
3333
/// - producingOutput: An output that should be returned when this worker is requested, if any.
3434
/// - key: Key to expect this `Workflow` to be rendered with.
35-
public func expectTask<Value>(
35+
public func expect<Value>(
3636
task: Task<Value, Never>.Type,
3737
output: Value,
3838
key: String = ""

WorkflowConcurrency/TestingTests/TaskTests.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ class TaskTests: XCTestCase {
2525
func testTaskWorkflow() {
2626
TestWorkflow()
2727
.renderTester()
28-
.expectTask(task: Task<Int, Never>.self, output: 1, key: "123")
28+
.expect(task: Task<Int, Never>.self, output: 1, key: "123")
2929
.render {}
3030
}
3131

0 commit comments

Comments
 (0)