Mercurial > hg > nginx-tests
annotate auth_request_satisfy.t @ 1990:85d88cd5091c
Tests: SSI include stub tests.
author | Maxim Dounin <mdounin@mdounin.ru> |
---|---|
date | Thu, 04 Jul 2024 17:42:55 +0300 |
parents | 882267679006 |
children |
rev | line source |
---|---|
349
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
1 #!/usr/bin/perl |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
2 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
3 # (C) Maxim Dounin |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
4 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
5 # Tests for auth request module with satisfy directive. |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
6 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
7 ############################################################################### |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
8 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
9 use warnings; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
10 use strict; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
11 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
12 use Test::More; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
13 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
14 BEGIN { use FindBin; chdir($FindBin::Bin); } |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
15 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
16 use lib 'lib'; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
17 use Test::Nginx; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
18 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
19 ############################################################################### |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
20 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
21 select STDERR; $| = 1; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
22 select STDOUT; $| = 1; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
23 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
24 my $t = Test::Nginx->new() |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
25 ->has(qw/http rewrite access auth_basic auth_request/) |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
26 ->plan(18); |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
27 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
28 $t->write_file_expand('nginx.conf', <<'EOF'); |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
29 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
30 %%TEST_GLOBALS%% |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
31 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
32 daemon off; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
33 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
34 events { |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
35 } |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
36 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
37 http { |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
38 %%TEST_GLOBALS_HTTP%% |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
39 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
40 server { |
974
882267679006
Tests: simplified parallel modifications in tests.
Andrey Zelenkov <zelenkov@nginx.com>
parents:
952
diff
changeset
|
41 listen 127.0.0.1:8080; |
349
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
42 server_name localhost; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
43 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
44 location / { |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
45 return 444; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
46 } |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
47 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
48 location /all/allow { |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
49 satisfy all; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
50 allow all; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
51 auth_request /auth; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
52 } |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
53 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
54 location /all/deny { |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
55 satisfy all; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
56 deny all; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
57 auth_request /auth; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
58 } |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
59 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
60 location /all/basic { |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
61 satisfy all; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
62 auth_basic "restricted"; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
63 auth_basic_user_file %%TESTDIR%%/htpasswd; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
64 auth_request /auth; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
65 } |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
66 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
67 location /any/allow { |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
68 satisfy any; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
69 allow all; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
70 auth_request /auth; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
71 } |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
72 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
73 location /any/deny { |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
74 satisfy any; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
75 deny all; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
76 auth_request /auth; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
77 } |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
78 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
79 location /any/basic { |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
80 satisfy any; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
81 auth_basic "restricted"; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
82 auth_basic_user_file %%TESTDIR%%/htpasswd; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
83 auth_request /auth; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
84 } |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
85 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
86 location = /auth { |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
87 if ($request_uri ~ "open$") { |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
88 return 204; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
89 } |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
90 if ($request_uri ~ "unauthorized$") { |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
91 return 401; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
92 } |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
93 if ($request_uri ~ "forbidden$") { |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
94 return 403; |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
95 } |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
96 } |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
97 } |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
98 } |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
99 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
100 EOF |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
101 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
102 $t->write_file('htpasswd', 'user:{PLAIN}secret' . "\n"); |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
103 $t->run(); |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
104 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
105 ############################################################################### |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
106 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
107 # satisfy all - first 401/403 wins |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
108 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
109 like(http_get('/all/allow+open'), qr/ 404 /, 'all allow+open'); |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
110 like(http_get('/all/allow+unauthorized'), qr/ 401 /, 'all allow+unauthorized'); |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
111 like(http_get('/all/allow+forbidden'), qr/ 403 /, 'all allow+forbidden'); |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
112 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
113 like(http_get('/all/deny+open'), qr/ 403 /, 'all deny+open'); |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
114 like(http_get('/all/deny+unauthorized'), qr/ 403 /, 'all deny+unauthorized'); |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
115 like(http_get('/all/deny+forbidden'), qr/ 403 /, 'all deny+forbidden'); |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
116 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
117 like(http_get('/all/basic+open'), qr/ 401 /, 'all basic+open'); |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
118 like(http_get('/all/basic+unauthorized'), qr/ 401 /, 'all basic+unauthorized'); |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
119 like(http_get('/all/basic+forbidden'), qr/ 401 /, 'all basic+forbidden'); |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
120 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
121 # satisfy any - first ok wins |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
122 # additionally, 403 shouldn't override 401 status |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
123 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
124 like(http_get('/any/allow+open'), qr/ 404 /, 'any allow+open'); |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
125 like(http_get('/any/allow+unauthorized'), qr/ 404 /, 'any allow+unauthorized'); |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
126 like(http_get('/any/allow+forbidden'), qr/ 404 /, 'any allow+forbidden'); |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
127 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
128 like(http_get('/any/deny+open'), qr/ 404 /, 'any deny+open'); |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
129 like(http_get('/any/deny+unauthorized'), qr/ 401 /, 'any deny+unauthorized'); |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
130 like(http_get('/any/deny+forbidden'), qr/ 403 /, 'any deny+forbidden'); |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
131 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
132 like(http_get('/any/basic+open'), qr/ 404 /, 'any basic+open'); |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
133 like(http_get('/any/basic+unauthorized'), qr/ 401 /, 'any basic+unauthorized'); |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
134 like(http_get('/any/basic+forbidden'), qr/ 401 /, 'any basic+forbidden'); |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
135 |
918dc7aa50f1
Tests: tests for auth_request with satisfy.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
136 ############################################################################### |