MakeAWishFoundation/SwiftyMocky

Feature Request: View controller and view mocking support.

erneestoc opened this issue · 0 comments

I've been playing with the idea of allowing automocks of some core components of iOS applications.

For example:

protocol MyAwesomeViewControllerType: UIViewController, Automockable {
    init(myImportantParameter: Bool)
    func someUsefulFunction()
}

In this way I could register types on my DI system, and inject fake types on my test. The views or view controller would have a watermark with the names of the controller in case we use snapshot testing, and would allow us to assert the behavior we're using.

Any thoughts?