diff --git a/.travis.yml b/.travis.yml index 10c2ebed..36b8a13e 100644 --- a/.travis.yml +++ b/.travis.yml @@ -4,7 +4,7 @@ python: - 2.7 # TODO: Python 3 #- 3.2 -script: python setup.py test +script: python tests.py install: - pip install requests pygments - "if [[ $TRAVIS_PYTHON_VERSION == '2.6' ]]; then pip install argparse; fi" diff --git a/tests.py b/tests.py index e8a71128..276784f5 100644 --- a/tests.py +++ b/tests.py @@ -30,18 +30,18 @@ class BaseTest(unittest.TestCase): def assertNotIn(self, member, container, msg=None): sup = super(BaseTest, self) - if hasattr('sup', 'assertNotIn'): - sup.assertIn(member, container, msg) + if hasattr(sup, 'assertNotIn'): + sup.assertNotIn(member, container, msg) else: self.assert_(member not in container, msg) def assertDictEqual(self, d1, d2, msg=None): sup = super(BaseTest, self) - if hasattr('sup', 'assertDictEqual'): - self.assertDictEqual(d1, d2, msg) + if hasattr(sup, 'assertDictEqual'): + sup.assertDictEqual(d1, d2, msg) else: - sup.assertEqual(set(d1.keys()), set(d2.keys()), msg) - sup.assertEqual(sorted(d1.values()), sorted(d2.values()), msg) + self.assertEqual(set(d1.keys()), set(d2.keys()), msg) + self.assertEqual(sorted(d1.values()), sorted(d2.values()), msg) class TestItemParsing(BaseTest):