Move actions out of test app
[catagits/Catalyst-Authentication-Credential-HTTP.git] / t / lib / AuthDigestTestApp.pm
1 package AuthDigestTestApp;
2 use Catalyst qw/
3     Authentication
4     Cache
5 /;
6
7 our %users;
8 my $digest_pass = Digest::MD5->new;
9 $digest_pass->add('Mufasa2:testrealm@host.com:Circle Of Life');
10 %users = (
11         Mufasa  => { pass         => "Circle Of Life",          },
12         Mufasa2 => { pass         => $digest_pass->hexdigest, },
13 );
14 __PACKAGE__->config(
15     cache => {
16         backend => {
17             class => 'Cache::FileCache',
18         },
19     },
20     authentication => {
21         default_realm => 'testrealm@host.com',
22         realms => {
23             'testrealm@host.com' => {
24                 store => {
25                     class => 'Minimal',
26                     users => \%users,
27                 },
28                 credential => {
29                     class => 'HTTP',
30                     type  => 'digest',
31                     password_type => 'clear',
32                     password_field => 'pass'
33                 },
34             },
35         },
36     },
37 );
38 __PACKAGE__->setup;
39
40 1;
41