iOS单元测试和UI测试全面解析(26)
发表于:2017-03-31来源:51CTO作者:朱先忠点击数:
标签:单元测试iOS
promise.fulfill() self.controllerUnderTest?.updateSearchResults(data) } } } dataTask?.resume() waitForExpectations(timeout:5,handler:nil) // then XCTAssertEqual(controllerUnderTest?.searchResults. cou
promise.fulfill()
self.controllerUnderTest?.updateSearchResults(data)
}
}
}
dataTask?.resume()
waitForExpectations(timeout: 5, handler: nil)
// then
XCTAssertEqual(controllerUnderTest?.searchResults.count
原文转自:http://mobile.51cto.com/iphone-535758.htm