mirror of
https://github.com/pi-hole/docker-pi-hole.git
synced 2024-06-21 06:56:53 +02:00
rest of loading tests fixed, undo heredoc tab2space
This commit is contained in:
parent
988e17be7a
commit
7c6c48e133
|
@ -174,11 +174,11 @@ setup_php_env_debian() {
|
|||
setup_php_env_alpine() {
|
||||
# Intentionally tabs, required by HEREDOC de-indentation (<<-)
|
||||
cat <<-EOF > "$PHP_ENV_CONFIG"
|
||||
[www]
|
||||
env[PATH] = ${PATH}
|
||||
env[PHP_ERROR_LOG] = ${PHP_ERROR_LOG}
|
||||
env[ServerIP] = ${ServerIP}
|
||||
EOF
|
||||
[www]
|
||||
env[PATH] = ${PATH}
|
||||
env[PHP_ERROR_LOG] = ${PHP_ERROR_LOG}
|
||||
env[ServerIP] = ${ServerIP}
|
||||
EOF
|
||||
|
||||
if [ -z "$VIRTUAL_HOST" ] ; then
|
||||
VIRTUAL_HOST="$ServerIP"
|
||||
|
@ -277,8 +277,8 @@ test_framework_stubbing() {
|
|||
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)"
|
||||
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 'http://localhost/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.list
|
||||
fi
|
||||
}
|
||||
|
||||
|
|
|
@ -56,7 +56,7 @@ def test_html_index_requests_load_as_expected(RunningPiHole, Slow, addr, url):
|
|||
assert http_rc.rc == 0
|
||||
assert int(http_rc.stdout) == 200
|
||||
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('url', [ '/index.js', '/any.js'] )
|
||||
|
|
Loading…
Reference in New Issue
Block a user