danielsaidi / MockingKit

MockingKit is a Swift SDK that lets you easily mock protocols and classes in `Swift`.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Mock doesn't work in Xcode 12

danielsaidi opened this issue · comments

In Xcode 12, the memory address of a function is new every time it's called.

This makes registering results, inspecting calls etc. not work, since a function doesn't get a fixed memory address.

If we manage to solve this in a better way, we will probably solve the other bugs as well.

I managed to solve this with a new MockReference type that uniquely identifies a function.