##// END OF EJS Templates
Python 2.6: Add `assert_is_none`, `assert_is_not_none` to `nose.tools`.
Bradley M. Froehle -
Show More
@@ -15,3 +15,15 def assert_not_in(item, collection):
15
15
16 if not hasattr(nt, 'assert_not_in'):
16 if not hasattr(nt, 'assert_not_in'):
17 nt.assert_not_in = assert_not_in
17 nt.assert_not_in = assert_not_in
18
19 def assert_is_none(obj):
20 assert obj is None, '%r is not None' % obj
21
22 if not hasattr(nt, 'assert_is_none'):
23 nt.assert_is_none = assert_is_none
24
25 def assert_is_not_none(obj):
26 assert obj is not None, '%r is None' % obj
27
28 if not hasattr(nt, 'assert_is_not_none'):
29 nt.assert_is_not_none = assert_is_not_none
General Comments 0
You need to be logged in to leave comments. Login now