From 6b068a141d1f3d63ab0593c060ead5fcdb3d5bab Mon Sep 17 00:00:00 2001 From: Tim Byrne Date: Mon, 21 Dec 2020 15:38:31 -0600 Subject: [PATCH] Remove superfluous f-strings --- test/test_ext_crypt.py | 2 +- test/test_hooks.py | 2 +- test/test_unit_set_local_alt_values.py | 4 ++-- test/test_unit_template_default.py | 4 ++-- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/test/test_ext_crypt.py b/test/test_ext_crypt.py index 0856b86..9eefc98 100644 --- a/test/test_ext_crypt.py +++ b/test/test_ext_crypt.py @@ -22,7 +22,7 @@ def test_ext_encryption(runner, yadm, paths, tmpdir, crypt, cmd, var): pgm = bindir.join('test-ext-crypt') if crypt: - pgm.write(f'#!/bin/sh\necho ext-crypt ran\n') + pgm.write('#!/bin/sh\necho ext-crypt ran\n') pgm.chmod(0o775) if crypt == 'installed-but-failed': pgm.write('false\n', mode='a') diff --git a/test/test_hooks.py b/test/test_hooks.py index 1c75ee9..19eb95c 100644 --- a/test/test_hooks.py +++ b/test/test_hooks.py @@ -78,7 +78,7 @@ def test_hook_env(runner, yadm_cmd, paths): assert f'YADM_HOOK_FULL_COMMAND={cmd} extra_args\n' in run.out assert f'YADM_HOOK_REPO={paths.repo}\n' in run.out assert f'YADM_HOOK_WORK={paths.work}\n' in run.out - assert f'YADM_ENCRYPT_INCLUDE_FILES=\n' in run.out + assert 'YADM_ENCRYPT_INCLUDE_FILES=\n' in run.out # verify the hook environment contains certain exported functions for func in [ diff --git a/test/test_unit_set_local_alt_values.py b/test/test_unit_set_local_alt_values.py index 827840f..15df5c2 100644 --- a/test/test_unit_set_local_alt_values.py +++ b/test/test_unit_set_local_alt_values.py @@ -52,12 +52,12 @@ def test_set_local_alt_values( assert f"os='{tst_sys}'" in run.out if override == 'hostname': - assert f"host='override'" in run.out + assert "host='override'" in run.out else: assert f"host='{tst_host}'" in run.out if override == 'user': - assert f"user='override'" in run.out + assert "user='override'" in run.out else: assert f"user='{tst_user}'" in run.out diff --git a/test/test_unit_template_default.py b/test/test_unit_template_default.py index 861f190..639cb29 100644 --- a/test/test_unit_template_default.py +++ b/test/test_unit_template_default.py @@ -89,8 +89,8 @@ end of template ''' INCLUDE_BASIC = 'basic\n' -INCLUDE_VARIABLES = f'''\ -included <{{{{ yadm.class }}}}> file +INCLUDE_VARIABLES = '''\ +included <{{ yadm.class }}> file empty line above '''