mirror of
https://github.com/pi-hole/pi-hole.git
synced 2024-12-24 13:50:17 +00:00
add test for unsupported distro checking
Signed-off-by: bcambl <blayne@blaynecampbell.com>
This commit is contained in:
parent
553aad6ed2
commit
09d40679c0
1 changed files with 16 additions and 0 deletions
|
@ -10,6 +10,22 @@ from conftest import (
|
|||
)
|
||||
|
||||
|
||||
def test_supported_operating_system(Pihole):
|
||||
'''
|
||||
confirm installer exists on unsupported distribution
|
||||
'''
|
||||
# break supported package managers to emulate an unsupported distribution
|
||||
Pihole.run('rm -rf /usr/bin/apt-get')
|
||||
Pihole.run('rm -rf /usr/bin/rpm')
|
||||
distro_check = Pihole.run('''
|
||||
source /opt/pihole/basic-install.sh
|
||||
distro_check
|
||||
''')
|
||||
expected_stdout = cross_box + ' OS distribution not supported'
|
||||
assert expected_stdout in distro_check.stdout
|
||||
# assert distro_check.rc == 1
|
||||
|
||||
|
||||
def test_setupVars_are_sourced_to_global_scope(Pihole):
|
||||
'''
|
||||
currently update_dialogs sources setupVars with a dot,
|
||||
|
|
Loading…
Reference in a new issue