Created
February 4, 2014 17:02
-
-
Save zzzeek/8807841 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
>>> import mock | |
>>> sess = mock.Mock() | |
>>> sess.query().filter(x=2).first.return_value = 5 | |
>>> sess.query().filter(x=2).first() | |
5 | |
>>> sess.query().filter(x=3).first() # <-- should not return 5, I'd like the "x=2" to be significant | |
5 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment