remove no longer needed tests

Signed-off-by: Adam Warner <adamw@rner.email>
This commit is contained in:
Adam Warner 2017-09-09 19:41:05 +01:00
parent 5f4be0de35
commit 42b5574f9b
No known key found for this signature in database
GPG key ID: 03843F6C65554B22

View file

@ -189,107 +189,6 @@ def test_installPiholeWeb_fresh_install_no_errors(Pihole):
assert 'index.js' in web_directory assert 'index.js' in web_directory
assert 'blockingpage.css' in web_directory assert 'blockingpage.css' in web_directory
def test_installPiholeWeb_empty_directory_no_errors(Pihole):
''' confirms all web page assets from Core repo are installed in an emtpy directory '''
installWeb = Pihole.run('''
source /opt/pihole/basic-install.sh
mkdir -p /var/www/html/pihole
installPiholeWeb
''')
assert info_box + ' Installing blocking page...' in installWeb.stdout
assert info_box + ' Installing index.php' in installWeb.stdout
assert info_box + ' Installing index.js' in installWeb.stdout
assert info_box + ' Installing blockingpage.css' in installWeb.stdout
assert 'No default index.lighttpd.html file found... not backing up' not in installWeb.stdout
assert tick_box + ' Installing sudoer file' in installWeb.stdout
web_directory = Pihole.run('ls -r /var/www/html/pihole').stdout
assert 'index.php' in web_directory
assert 'index.js' in web_directory
assert 'blockingpage.css' in web_directory
def test_installPiholeWeb_index_php_no_errors(Pihole):
''' confirms all web page assets from Core repo are installed when necessary '''
installWeb = Pihole.run('''
source /opt/pihole/basic-install.sh
mkdir -p /var/www/html/pihole
touch /var/www/html/pihole/index.php
installPiholeWeb
''')
assert info_box + ' Installing blocking page...' in installWeb.stdout
assert info_box + ' Installing index.php' in installWeb.stdout
assert 'detected index.php, not overwriting' in installWeb.stdout
assert info_box + ' Installing index.js' in installWeb.stdout
assert info_box + ' Installing blockingpage.css' in installWeb.stdout
assert 'No default index.lighttpd.html file found... not backing up' not in installWeb.stdout
assert tick_box + ' Installing sudoer file' in installWeb.stdout
web_directory = Pihole.run('ls -r /var/www/html/pihole').stdout
assert 'index.php' in web_directory
assert 'index.js' in web_directory
assert 'blockingpage.css' in web_directory
def test_installPiholeWeb_index_js_no_errors(Pihole):
''' confirms all web page assets from Core repo are installed when necessary '''
installWeb = Pihole.run('''
source /opt/pihole/basic-install.sh
mkdir -p /var/www/html/pihole
touch /var/www/html/pihole/index.js
installPiholeWeb
''')
assert info_box + ' Installing blocking page...' in installWeb.stdout
assert info_box + ' Installing index.php' in installWeb.stdout
assert info_box + ' Installing index.js' in installWeb.stdout
assert 'detected index.js, not overwriting' in installWeb.stdout
assert info_box + ' Installing blockingpage.css' in installWeb.stdout
assert 'No default index.lighttpd.html file found... not backing up' not in installWeb.stdout
assert tick_box + ' Installing sudoer file' in installWeb.stdout
web_directory = Pihole.run('ls -r /var/www/html/pihole').stdout
assert 'index.php' in web_directory
assert 'index.js' in web_directory
assert 'blockingpage.css' in web_directory
def test_installPiholeWeb_blockingpage_css_no_errors(Pihole):
''' confirms all web page assets from Core repo are installed when necessary '''
installWeb = Pihole.run('''
source /opt/pihole/basic-install.sh
mkdir -p /var/www/html/pihole
touch /var/www/html/pihole/blockingpage.css
installPiholeWeb
''')
assert info_box + ' Installing blocking page...' in installWeb.stdout
assert info_box + ' Installing index.php' in installWeb.stdout
assert info_box + ' Installing index.js' in installWeb.stdout
assert info_box + ' Installing blockingpage.css' in installWeb.stdout
assert 'detected blockingpage.css, not overwriting' in installWeb.stdout
assert 'No default index.lighttpd.html file found... not backing up' not in installWeb.stdout
assert tick_box + ' Installing sudoer file' in installWeb.stdout
web_directory = Pihole.run('ls -r /var/www/html/pihole').stdout
assert 'index.php' in web_directory
assert 'index.js' in web_directory
assert 'blockingpage.css' in web_directory
def test_installPiholeWeb_already_populated_no_errors(Pihole):
''' confirms all web page assets from Core repo are installed when necessary '''
installWeb = Pihole.run('''
source /opt/pihole/basic-install.sh
mkdir -p /var/www/html/pihole
touch /var/www/html/pihole/index.php
touch /var/www/html/pihole/index.js
touch /var/www/html/pihole/blockingpage.css
installPiholeWeb
''')
assert info_box + ' Installing blocking page...' in installWeb.stdout
assert info_box + ' Installing index.php' in installWeb.stdout
assert 'detected index.php, not overwriting' in installWeb.stdout
assert info_box + ' Installing index.js' in installWeb.stdout
assert 'detected index.js, not overwriting' in installWeb.stdout
assert info_box + ' Installing blockingpage.css' in installWeb.stdout
assert 'detected blockingpage.css, not overwriting' in installWeb.stdout
assert tick_box + ' Installing sudoer file' in installWeb.stdout
web_directory = Pihole.run('ls -r /var/www/html/pihole').stdout
assert 'index.php' in web_directory
assert 'index.js' in web_directory
assert 'blockingpage.css' in web_directory
def test_update_package_cache_success_no_errors(Pihole): def test_update_package_cache_success_no_errors(Pihole):
''' confirms package cache was updated without any errors''' ''' confirms package cache was updated without any errors'''
updateCache = Pihole.run(''' updateCache = Pihole.run('''