From a7c51ae09390903445ae56954d80c6fc3e1ddb6c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ionel=20Cristian=20M=C4=83rie=C8=99?= Date: Wed, 7 Oct 2015 23:25:10 +0300 Subject: [PATCH] Fix assertions. --- tests/test_tax.py | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/tests/test_tax.py b/tests/test_tax.py index fc86678..628dd5f 100644 --- a/tests/test_tax.py +++ b/tests/test_tax.py @@ -4,17 +4,16 @@ def test_main(testdir): - testdir.makefile('.ini', tox="""[tox] + testdir.makefile('.ini', tox=r"""[tox] envlist = foobar skipsdist = true [testenv] commands = - python -c "import sys; print('sys.executable=%%r' %% sys.executable)" - python -c "import sys; sys.executable == %r and sys.stdout.write('OK\\n')" -""" % ( - sys.executable, - )) + python -c "import sys; print('sys.executable=%r' % sys.executable)" + python -c "import sys; sys.stdout.write('OK\n') if {0!r}.startswith(sys.executable) or sys.executable.startswith({0!r}) else sys.stdout.write('BAD\n')" +""".format(sys.executable)) + result = testdir.run('tax', '-e', 'foobar') result.stdout.fnmatch_lines([ "foobar create: *",