Slide 44
Slide 44 text
class FakeSearchEventModel: SearchEventModelProtocol {
var search_successValue = [ConnpassEvent]()
func search(searchWord: String, completion: @escaping ((Result<[ConnpassEvent]>) -> ())) {
search_callCount += 1
search_arguments = searchWord
completion(.success(search_successValue))
}
}
class FakeFailureSearchEventModel: SearchEventModelProtocol {
func search(searchWord: String, completion: @escaping ((Result<[ConnpassEvent]>) -> ())) {
search_arguments = searchWord
completion(.failure)
}
}
ελϒ
ґଘ͢ΔΦϒδΣΫτͷ݁ՌΛ
ίϯτϩʔϧͰ͖Δ