A natural counterpart to the ANY helper is the NOT helper, which would allow
you to assert that an argument or value is anything except some certain value.
Example:
>>> mock = Mock(return_value=None)
>>> mock('foo')
>>> mock.assert_called_once_with(NOT('bar', 'baz', 'qux'))
Attached is a patch for NOT with tests and mediocre documentation. Let me know
if any more changes are needed. :D
Original issue reported on code.google.com by Osmose1...@gmail.com on 6 Nov 2012 at 4:19
Original issue reported on code.google.com by
Osmose1...@gmail.com
on 6 Nov 2012 at 4:19Attachments: