Skip to content

Commit

Permalink
Changed expectPublisher/expectTask to be expect
Browse files Browse the repository at this point in the history
  • Loading branch information
mjohnson12 committed Oct 3, 2022
1 parent 34ab24f commit 998c080
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
8 changes: 4 additions & 4 deletions WorkflowCombine/Testing/PublisherTesting.swift
Original file line number Diff line number Diff line change
Expand Up @@ -22,17 +22,17 @@
import XCTest
@testable import WorkflowCombine

@available(macOS 10.15, *)
@available(iOS 13.0, *)
extension RenderTester {
@available(macOS 10.15, *)
@available(iOS 13.0, *)
extension RenderTester {
/// Expect a `Publisher`s.
///
/// `PublisherWorkflow` is used to subscribe to `Publisher`s.
///
/// - Parameters:
/// - producingOutput: An output that should be returned when this worker is requested, if any.
/// - key: Key to expect this `Workflow` to be rendered with.
public func expectPublisher<PublisherType: Publisher>(
public func expect<PublisherType: Publisher>(
publisher: PublisherType.Type,
output: PublisherType.Output,
key: String = ""
Expand Down
2 changes: 1 addition & 1 deletion WorkflowCombine/TestingTests/PublisherTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ class PublisherTests: XCTestCase {
func testPublisherWorkflow() {
TestWorkflow()
.renderTester()
.expectPublisher(publisher: Publishers.Sequence<[Int], Never>.self, output: 1, key: "123")
.expect(publisher: Publishers.Sequence<[Int], Never>.self, output: 1, key: "123")
.render {}
}

Expand Down
2 changes: 1 addition & 1 deletion WorkflowConcurrency/Testing/TaskTesting.swift
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
/// - Parameters:
/// - producingOutput: An output that should be returned when this worker is requested, if any.
/// - key: Key to expect this `Workflow` to be rendered with.
public func expectTask<Value>(
public func expect<Value>(
task: Task<Value, Never>.Type,
output: Value,
key: String = ""
Expand Down
2 changes: 1 addition & 1 deletion WorkflowConcurrency/TestingTests/TaskTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ class TaskTests: XCTestCase {
func testTaskWorkflow() {
TestWorkflow()
.renderTester()
.expectTask(task: Task<Int, Never>.self, output: 1, key: "123")
.expect(task: Task<Int, Never>.self, output: 1, key: "123")
.render {}
}

Expand Down

0 comments on commit 998c080

Please sign in to comment.