Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
final class ImageHavingStub: ImageHaving {
var expectedImage = UIImage()
var givenError: Error? = nil
var image: Observable<UIImage> {
if let error = givenError {
return .error(error)
}
return .just(expectedImage)
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.