mirror of
https://github.com/pi-hole/docker-pi-hole.git
synced 2025-12-22 19:39:00 +00:00
rest of loading tests fixed, undo heredoc tab2space
This commit is contained in:
@@ -277,8 +277,8 @@ test_framework_stubbing() {
|
|||||||
echo ":::::: Tests are being ran - stub out ad list fetching and add a fake ad block"
|
echo ":::::: Tests are being ran - stub out ad list fetching and add a fake ad block"
|
||||||
sed -i 's/^gravity_spinup$/#gravity_spinup # DISABLED FOR PYTEST/g' "$(which gravity.sh)"
|
sed -i 's/^gravity_spinup$/#gravity_spinup # DISABLED FOR PYTEST/g' "$(which gravity.sh)"
|
||||||
echo '123.123.123.123 testblock.pi-hole.local' > /var/www/html/fake.list
|
echo '123.123.123.123 testblock.pi-hole.local' > /var/www/html/fake.list
|
||||||
echo 'file:///var/www/html/fake.list' > /etc/pihole/adlists.txt
|
echo 'file:///var/www/html/fake.list' > /etc/pihole/adlists.list
|
||||||
echo 'http://localhost/fake.list' >> /etc/pihole/adlists.txt
|
echo 'http://localhost/fake.list' >> /etc/pihole/adlists.list
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -56,7 +56,7 @@ def test_html_index_requests_load_as_expected(RunningPiHole, Slow, addr, url):
|
|||||||
assert http_rc.rc == 0
|
assert http_rc.rc == 0
|
||||||
assert int(http_rc.stdout) == 200
|
assert int(http_rc.stdout) == 200
|
||||||
page_contents = RunningPiHole.run('cat /tmp/curled_file ').stdout
|
page_contents = RunningPiHole.run('cat /tmp/curled_file ').stdout
|
||||||
assert 'blocked' in page_contents
|
assert 'testblock.pi-hole.local' in page_contents
|
||||||
|
|
||||||
@pytest.mark.parametrize('addr', [ 'testblock.pi-hole.local' ])
|
@pytest.mark.parametrize('addr', [ 'testblock.pi-hole.local' ])
|
||||||
@pytest.mark.parametrize('url', [ '/index.js', '/any.js'] )
|
@pytest.mark.parametrize('url', [ '/index.js', '/any.js'] )
|
||||||
|
|||||||
Reference in New Issue
Block a user