Start test templates.

This commit is contained in:
Dan Schaper 2017-01-28 15:44:31 -08:00
parent 0375a3caa3
commit 2d18b2d784
No known key found for this signature in database
GPG key ID: 572E999E385B7BFC
2 changed files with 14 additions and 4 deletions

View file

@ -274,6 +274,15 @@ def test_installPiholeWeb_already_populated_no_errors(Pihole):
assert 'index.js' in web_directory
assert 'blockingpage.css' in web_directory
def test_update_package_cache_success_no_errors(Pihole):
''' confirms package cache was updated without any errors'''
updateCache = Pihole.run('''
source /opt/pihole/basic-install.sh
update_package_cache
''')
assert 'Updating local cache of available packages...' in updateCache.stdout
assert 'done!' in updateCache.stdout
# Helper functions
def mock_command(script, args, container):
''' Allows for setup of commands we don't really want to have to run for real in unit tests '''