@@ -16,27 +16,27 @@ final class ViewModelTests: XCTestCase {
1616
1717 sut. initializeService ( with: serviceName)
1818
19- XCTAssertTrue ( serviceSpy. initializeWithNameSecondNameCalled )
20- XCTAssertEqual ( serviceSpy. initializeWithNameSecondNameReceivedArguments ? . name, serviceName)
19+ XCTAssertTrue ( serviceSpy. initializeNameCalled )
20+ XCTAssertEqual ( serviceSpy. initializeNameReceivedArguments ? . name, serviceName)
2121 }
2222
2323 func testSaveConfig( ) async throws {
2424 let expectedConfig : [ String : String ] = [ " key " : " value " ]
2525
26- serviceSpy. fetchConfigWithArgReturnValue = expectedConfig
26+ serviceSpy. fetchConfigArgReturnValue = expectedConfig
2727
2828 try await sut. saveConfig ( )
2929
3030 XCTAssertEqual ( sut. config, expectedConfig)
3131
32- XCTAssertEqual ( serviceSpy. fetchConfigWithArgCallsCount , 1 )
33- XCTAssertEqual ( serviceSpy. fetchConfigWithArgReceivedInvocations , [ 1 ] )
32+ XCTAssertEqual ( serviceSpy. fetchConfigArgCallsCount , 1 )
33+ XCTAssertEqual ( serviceSpy. fetchConfigArgReceivedInvocations , [ 1 ] )
3434
3535 try await sut. saveConfig ( )
3636
3737 XCTAssertTrue ( sut. config. isEmpty)
3838
39- XCTAssertEqual ( serviceSpy. fetchConfigWithArgCallsCount , 2 )
40- XCTAssertEqual ( serviceSpy. fetchConfigWithArgReceivedInvocations , [ 1 , 2 ] )
39+ XCTAssertEqual ( serviceSpy. fetchConfigArgCallsCount , 2 )
40+ XCTAssertEqual ( serviceSpy. fetchConfigArgReceivedInvocations , [ 1 , 2 ] )
4141 }
4242}
0 commit comments