Skip to content
This repository has been archived by the owner on Mar 22, 2018. It is now read-only.

Commit

Permalink
assertIsNone was new in 2.7, do not use it in 2.6.
Browse files Browse the repository at this point in the history
  • Loading branch information
Mario Frasca committed Jan 3, 2015
1 parent 3f552bc commit e2b4318
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion bauble/test/test_search.py
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,13 @@ def test_look_for_wrong_strategy(self):
"verify the NotExisting strategy gives None"

mapper_search = search.get_strategy('NotExisting')
self.assertIsNone(mapper_search)

# assertIsNone is not available before 2.7
import sys
if sys.version_info[:2] <= (2, 6):
self.assertTrue(mapper_search is None)
elif sys.version_info[:2] >= (2, 7):
self.assertIsNone(mapper_search)

def test_search_by_values(self):
"""
Expand Down

0 comments on commit e2b4318

Please sign in to comment.