I am staring to use OCMockito for Unit Testing. Right now I am using it to mock a UserDefaults
(through dependency injection).
I can control what is returned back by:
[given([mockUserDefaults objectForKey:@"some key"]) willReturn:@"a value I want"];
Now my question is: How do I check what values the user set to the mock UserDefaults
?
for example, if user issued:
[self.userDefaults setObject:[NSDate date] forKey:"example"];
How do I get the date
back from the mock userDefaults
?