mirror of
https://github.com/pi-hole/docker-pi-hole.git
synced 2026-05-08 09:48:31 +01:00
various test fixes
This commit is contained in:
@@ -9,7 +9,7 @@ run_local = testinfra.get_backend(
|
||||
@pytest.mark.parametrize("upstream,image,tag", [
|
||||
( 'alpine:edge', 'alpine.docker', 'diginc/pi-hole:alpine' ),
|
||||
( 'debian:jessie', 'debian.docker', 'diginc/pi-hole:debian' ),
|
||||
( 'jsurf/rpi-raspbian', 'debian-armhf.docker', 'diginc/pi-hole:arm' ),
|
||||
#( 'jsurf/rpi-raspbian', 'debian-armhf.docker', 'diginc/pi-hole:arm' ),
|
||||
])
|
||||
def test_build_pihole_image(upstream, image, tag):
|
||||
run_local('docker pull {}'.format(upstream))
|
||||
|
||||
+4
-1
@@ -38,7 +38,10 @@ def test_indecies_are_present(RunningPiHole):
|
||||
File('/var/www/html/pihole/index.html').exists
|
||||
File('/var/www/html/pihole/index.js').exists
|
||||
|
||||
@pytest.mark.parametrize('ip', [ '127.0.0.1', '[::]' ] )
|
||||
@pytest.mark.parametrize('ip,args', [
|
||||
('127.0.0.1', '-e ServerIP="192.168.100.2" -e VIRTUAL_HOST="127.0.0.1"'),
|
||||
('[::]', '-e ServerIP="192.168.100.2" -e VIRTUAL_HOST="[::]"')
|
||||
])
|
||||
@pytest.mark.parametrize('url', [ '/', '/index.html', '/any.html' ] )
|
||||
def test_html_index_requests_load_as_expected(RunningPiHole, ip, url):
|
||||
command = 'curl -s -o /tmp/curled_file -w "%{{http_code}}" http://{}{}'.format(ip, url)
|
||||
|
||||
Reference in New Issue
Block a user