#!/bin/sh

set -eu

REQUIRED_CMDLINE="-c examples/hostname_in_rootdir.conf"
. regression.inc

CODE=200
WPATH="/"

HOST="w1.example.com"
NAME="check ${HOST}"
do_request

HOST="w2.example.com"
NAME="check ${HOST}"
do_request

HOST="w3.example.com"
NAME="check ${HOST}"
do_request

HOST="www.example.org"
NAME="check ${HOST} (com != org)"
do_request

CODE=404

HOST="w4.example.com"
NAME="check ${HOST}"
do_request

HOST="proxy.example.org"
NAME="check ${HOST}"
do_request

echo "All tests passed"
