diff --git a/test/conftest.py b/test/conftest.py index 9bda397b..4e870263 100644 --- a/test/conftest.py +++ b/test/conftest.py @@ -100,7 +100,7 @@ def mock_command(script, args, container): in unit tests ''' full_script_path = '/usr/local/bin/{}'.format(script) - mock_script = dedent('''\ + mock_script = dedent(r'''\ #!/bin/bash -e echo "\$0 \$@" >> /var/log/{script} case "\$1" in'''.format(script=script)) @@ -127,7 +127,7 @@ def mock_command_run(script, args, container): in unit tests ''' full_script_path = '/usr/local/bin/{}'.format(script) - mock_script = dedent('''\ + mock_script = dedent(r'''\ #!/bin/bash -e echo "\$0 \$@" >> /var/log/{script} case "\$1 \$2" in'''.format(script=script)) @@ -154,7 +154,7 @@ def mock_command_2(script, args, container): in unit tests ''' full_script_path = '/usr/local/bin/{}'.format(script) - mock_script = dedent('''\ + mock_script = dedent(r'''\ #!/bin/bash -e echo "\$0 \$@" >> /var/log/{script} case "\$1 \$2" in'''.format(script=script)) diff --git a/test/test_automated_install.py b/test/test_automated_install.py index 3b5f3e17..8aa0773d 100644 --- a/test/test_automated_install.py +++ b/test/test_automated_install.py @@ -140,8 +140,8 @@ def get_directories_recursive(Pihole, directory): ls = Pihole.run('ls -d {}'.format(directory + '/*/')) directories = list(filter(bool, ls.stdout.splitlines())) dirs = directories - for dir in directories: - dir_rec = get_directories_recursive(Pihole, dir) + for dirval in directories: + dir_rec = get_directories_recursive(Pihole, dirval) if isinstance(dir_rec, str): dirs.extend([dir_rec]) else: @@ -513,6 +513,8 @@ def test_installPihole_fresh_install_readableBlockpage(Pihole, test_webpage): echo "INSTALL_WEB_SERVER=${INSTALL_WEB_SERVER}" ''') assert 0 == installWeb.rc + testFTL = Pihole.run('pihole-FTL test') + assert 0 == testFTL.rc piholeuser = 'pihole' webuser = '' user = re.findall(