From b99aace8a91b442a9c6e25081369fbd0fb15f96d Mon Sep 17 00:00:00 2001 From: Raphael Pierzina Date: Sun, 12 Jun 2016 00:52:03 +0100 Subject: [PATCH] Fix py26 by using indices in str.format --- _pytest/python.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/_pytest/python.py b/_pytest/python.py index a9243b36a..03792099a 100644 --- a/_pytest/python.py +++ b/_pytest/python.py @@ -1229,12 +1229,12 @@ def _show_fixtures_per_test(config, session): return if verbose > 0: bestrel = get_best_rel(fixture_def.func) - funcargspec = "{} -- {}".format(argname, bestrel) + funcargspec = "{0} -- {1}".format(argname, bestrel) else: funcargspec = argname tw.line(funcargspec, green=True) - INDENT = ' {}' + INDENT = ' {0}' fixture_doc = fixture_def.func.__doc__ if fixture_doc: @@ -1252,8 +1252,8 @@ def _show_fixtures_per_test(config, session): bestrel = get_best_rel(item.function) tw.line() - tw.sep('-', 'fixtures used by {}'.format(item.name)) - tw.sep('-', 'from {}'.format(bestrel)) + tw.sep('-', 'fixtures used by {0}'.format(item.name)) + tw.sep('-', 'from {0}'.format(bestrel)) for argname, fixture_defs in sorted(name2fixturedefs.items()): assert fixture_defs is not None if not fixture_defs: