The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.
use strict;
use warnings FATAL => 'all';

use Apache::Test;
use Apache::TestRequest;

plan tests => 4, have_lwp;

my $url = '/authz/index.html';

my $response = GET $url;

ok $response->code == 401;

ok $response->header('WWW-Authenticate') =~ m/Digest realm="flatfile"/;

$response = GET $url, username => 'geoff', password => 'geoff';

ok $response->code == 401;

$response = GET $url, username => 'test', password => 'test';

ok $response->code == 200;