From: noah morrison Date: Wed, 19 Nov 2014 03:42:19 +0000 (-0500) Subject: Fix python 2.6 failing X-Git-Url: https://git.devinivas.org/?a=commitdiff_plain;h=e334ff2121e5292ea3b630953346bcd7da859920;p=chevron.git Fix python 2.6 failing Thanks travis! --- diff --git a/test_spec.py b/test_spec.py index 69f9517..e5c8810 100755 --- a/test_spec.py +++ b/test_spec.py @@ -27,8 +27,8 @@ def _test_case_from_path(json_path): self.assertEqual(result, obj['expected']) - test_case.__doc__ = 'suite: {} desc: {}'.format(spec, - obj['desc']) + test_case.__doc__ = 'suite: {0} desc: {1}'.format(spec, + obj['desc']) return test_case with open(json_path, 'r') as f: @@ -36,7 +36,7 @@ def _test_case_from_path(json_path): # Generates a unit test for each test object for i, test in enumerate(yaml['tests']): - vars()['test_%s' % i] = _test_from_object(test) + vars()['test_' + str(i)] = _test_from_object(test) # Return the built class return MustacheTestCase