@@ -114,27 +114,27 @@ unlike(http_head('/'), qr/SEE-THIS/, 'proxy head request');
114
114
115
115
116
116
# Redirect (302)
117
- like(http_get(' /phase1?what=redirect302' ), qr / 302 Moved Temporarily / , ' redirect 302 - phase 1' );
118
- like(http_get(' /phase2?what=redirect302' ), qr / 302 Moved Temporarily / , ' redirect 302 - phase 2' );
119
- like(http_get(' /phase3?what=redirect302' ), qr / 302 Moved Temporarily / , ' redirect 302 - phase 3' );
117
+ like(http_get(' /phase1?what=redirect302' ), qr /^HTTP.* 302/ , ' redirect 302 - phase 1' );
118
+ like(http_get(' /phase2?what=redirect302' ), qr /^HTTP.* 302/ , ' redirect 302 - phase 2' );
119
+ like(http_get(' /phase3?what=redirect302' ), qr /^HTTP.* 302/ , ' redirect 302 - phase 3' );
120
120
is(http_get(' /phase4?what=redirect302' ), ' ' , ' redirect 302 - phase 4' );
121
121
122
122
# Redirect (301)
123
- like(http_get(' /phase1?what=redirect301' ), qr / 301 Moved Permanently / , ' redirect 301 - phase 1' );
124
- like(http_get(' /phase2?what=redirect301' ), qr / 301 Moved Permanently / , ' redirect 301 - phase 2' );
125
- like(http_get(' /phase3?what=redirect301' ), qr / 301 Moved Permanently / , ' redirect 301 - phase 3' );
123
+ like(http_get(' /phase1?what=redirect301' ), qr /^HTTP.* 301/ , ' redirect 301 - phase 1' );
124
+ like(http_get(' /phase2?what=redirect301' ), qr /^HTTP.* 301/ , ' redirect 301 - phase 2' );
125
+ like(http_get(' /phase3?what=redirect301' ), qr /^HTTP.* 301/ , ' redirect 301 - phase 3' );
126
126
is(http_get(' /phase4?what=redirect301' ), ' ' , ' redirect 301 - phase 4' );
127
127
128
128
# Block (401)
129
- like(http_get(' /phase1?what=block401' ), qr / 401 Unauthorized / , ' block 401 - phase 1' );
130
- like(http_get(' /phase2?what=block401' ), qr / 401 Unauthorized / , ' block 401 - phase 2' );
131
- like(http_get(' /phase3?what=block401' ), qr / 401 Unauthorized / , ' block 401 - phase 3' );
129
+ like(http_get(' /phase1?what=block401' ), qr /^HTTP.* 401/ , ' block 401 - phase 1' );
130
+ like(http_get(' /phase2?what=block401' ), qr /^HTTP.* 401/ , ' block 401 - phase 2' );
131
+ like(http_get(' /phase3?what=block401' ), qr /^HTTP.* 401/ , ' block 401 - phase 3' );
132
132
is(http_get(' /phase4?what=block401' ), ' ' , ' block 401 - phase 4' );
133
133
134
134
# Block (403)
135
- like(http_get(' /phase1?what=block403' ), qr / 403 Forbidden / , ' block 403 - phase 1' );
136
- like(http_get(' /phase2?what=block403' ), qr / 403 Forbidden / , ' block 403 - phase 2' );
137
- like(http_get(' /phase3?what=block403' ), qr / 403 Forbidden / , ' block 403 - phase 3' );
135
+ like(http_get(' /phase1?what=block403' ), qr /^HTTP.* 403/ , ' block 403 - phase 1' );
136
+ like(http_get(' /phase2?what=block403' ), qr /^HTTP.* 403/ , ' block 403 - phase 2' );
137
+ like(http_get(' /phase3?what=block403' ), qr /^HTTP.* 403/ , ' block 403 - phase 3' );
138
138
is(http_get(' /phase4?what=block403' ), ' ' , ' block 403 - phase 4' );
139
139
140
140
# Nothing to detect
0 commit comments