Skip to content

Commit 9ba3fea

Browse files
committed
test: fix incorrect sample HTTP responses
1 parent b936fcc commit 9ba3fea

File tree

2 files changed

+56
-56
lines changed

2 files changed

+56
-56
lines changed

tests/system/HTTP/CURLRequestDoNotShareOptionsTest.php

Lines changed: 28 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -404,20 +404,20 @@ public function testAuthBasicOptionExplicit(): void
404404
public function testAuthDigestOption(): void
405405
{
406406
$output = "HTTP/1.1 401 Unauthorized
407-
Server: ddos-guard
408-
Set-Cookie: __ddg1=z177j4mLtqzC07v0zviU; Domain=.site.ru; HttpOnly; Path=/; Expires=Wed, 07-Jul-2021 15:13:14 GMT
409-
WWW-Authenticate: Digest\x0d\x0a\x0d\x0aHTTP/1.1 200 OK
410-
Server: ddos-guard
411-
Connection: keep-alive
412-
Keep-Alive: timeout=60
413-
Set-Cookie: __ddg1=z177j4mLtqzC07v0zviU; Domain=.site.ru; HttpOnly; Path=/; Expires=Wed, 07-Jul-2021 15:13:14 GMT
414-
Date: Tue, 07 Jul 2020 15:13:14 GMT
415-
Expires: Thu, 19 Nov 1981 08:52:00 GMT
416-
Cache-Control: no-store, no-cache, must-revalidate
417-
Pragma: no-cache
418-
Set-Cookie: PHPSESSID=80pd3hlg38mvjnelpvokp9lad0; path=/
419-
Content-Type: application/xml; charset=utf-8
420-
Transfer-Encoding: chunked\x0d\x0a\x0d\x0a<title>Update success! config</title>";
407+
Server: ddos-guard
408+
Set-Cookie: __ddg1=z177j4mLtqzC07v0zviU; Domain=.site.ru; HttpOnly; Path=/; Expires=Wed, 07-Jul-2021 15:13:14 GMT
409+
WWW-Authenticate: Digest\x0d\x0a\x0d\x0aHTTP/1.1 200 OK
410+
Server: ddos-guard
411+
Connection: keep-alive
412+
Keep-Alive: timeout=60
413+
Set-Cookie: __ddg1=z177j4mLtqzC07v0zviU; Domain=.site.ru; HttpOnly; Path=/; Expires=Wed, 07-Jul-2021 15:13:14 GMT
414+
Date: Tue, 07 Jul 2020 15:13:14 GMT
415+
Expires: Thu, 19 Nov 1981 08:52:00 GMT
416+
Cache-Control: no-store, no-cache, must-revalidate
417+
Pragma: no-cache
418+
Set-Cookie: PHPSESSID=80pd3hlg38mvjnelpvokp9lad0; path=/
419+
Content-Type: application/xml; charset=utf-8
420+
Transfer-Encoding: chunked\x0d\x0a\x0d\x0a<title>Update success! config</title>";
421421

422422
$this->request->setOutput($output);
423423

@@ -457,20 +457,20 @@ public function testSetAuthBasic(): void
457457
public function testSetAuthDigest(): void
458458
{
459459
$output = "HTTP/1.1 401 Unauthorized
460-
Server: ddos-guard
461-
Set-Cookie: __ddg1=z177j4mLtqzC07v0zviU; Domain=.site.ru; HttpOnly; Path=/; Expires=Wed, 07-Jul-2021 15:13:14 GMT
462-
WWW-Authenticate: Digest\x0d\x0a\x0d\x0aHTTP/1.1 200 OK
463-
Server: ddos-guard
464-
Connection: keep-alive
465-
Keep-Alive: timeout=60
466-
Set-Cookie: __ddg1=z177j4mLtqzC07v0zviU; Domain=.site.ru; HttpOnly; Path=/; Expires=Wed, 07-Jul-2021 15:13:14 GMT
467-
Date: Tue, 07 Jul 2020 15:13:14 GMT
468-
Expires: Thu, 19 Nov 1981 08:52:00 GMT
469-
Cache-Control: no-store, no-cache, must-revalidate
470-
Pragma: no-cache
471-
Set-Cookie: PHPSESSID=80pd3hlg38mvjnelpvokp9lad0; path=/
472-
Content-Type: application/xml; charset=utf-8
473-
Transfer-Encoding: chunked\x0d\x0a\x0d\x0a<title>Update success! config</title>";
460+
Server: ddos-guard
461+
Set-Cookie: __ddg1=z177j4mLtqzC07v0zviU; Domain=.site.ru; HttpOnly; Path=/; Expires=Wed, 07-Jul-2021 15:13:14 GMT
462+
WWW-Authenticate: Digest\x0d\x0a\x0d\x0aHTTP/1.1 200 OK
463+
Server: ddos-guard
464+
Connection: keep-alive
465+
Keep-Alive: timeout=60
466+
Set-Cookie: __ddg1=z177j4mLtqzC07v0zviU; Domain=.site.ru; HttpOnly; Path=/; Expires=Wed, 07-Jul-2021 15:13:14 GMT
467+
Date: Tue, 07 Jul 2020 15:13:14 GMT
468+
Expires: Thu, 19 Nov 1981 08:52:00 GMT
469+
Cache-Control: no-store, no-cache, must-revalidate
470+
Pragma: no-cache
471+
Set-Cookie: PHPSESSID=80pd3hlg38mvjnelpvokp9lad0; path=/
472+
Content-Type: application/xml; charset=utf-8
473+
Transfer-Encoding: chunked\x0d\x0a\x0d\x0a<title>Update success! config</title>";
474474

475475
$this->request->setOutput($output);
476476

tests/system/HTTP/CURLRequestTest.php

Lines changed: 28 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -387,20 +387,20 @@ public function testAuthBasicOptionExplicit(): void
387387
public function testAuthDigestOption(): void
388388
{
389389
$output = "HTTP/1.1 401 Unauthorized
390-
Server: ddos-guard
391-
Set-Cookie: __ddg1=z177j4mLtqzC07v0zviU; Domain=.site.ru; HttpOnly; Path=/; Expires=Wed, 07-Jul-2021 15:13:14 GMT
392-
WWW-Authenticate: Digest\x0d\x0a\x0d\x0aHTTP/1.1 200 OK
393-
Server: ddos-guard
394-
Connection: keep-alive
395-
Keep-Alive: timeout=60
396-
Set-Cookie: __ddg1=z177j4mLtqzC07v0zviU; Domain=.site.ru; HttpOnly; Path=/; Expires=Wed, 07-Jul-2021 15:13:14 GMT
397-
Date: Tue, 07 Jul 2020 15:13:14 GMT
398-
Expires: Thu, 19 Nov 1981 08:52:00 GMT
399-
Cache-Control: no-store, no-cache, must-revalidate
400-
Pragma: no-cache
401-
Set-Cookie: PHPSESSID=80pd3hlg38mvjnelpvokp9lad0; path=/
402-
Content-Type: application/xml; charset=utf-8
403-
Transfer-Encoding: chunked\x0d\x0a\x0d\x0a<title>Update success! config</title>";
390+
Server: ddos-guard
391+
Set-Cookie: __ddg1=z177j4mLtqzC07v0zviU; Domain=.site.ru; HttpOnly; Path=/; Expires=Wed, 07-Jul-2021 15:13:14 GMT
392+
WWW-Authenticate: Digest\x0d\x0a\x0d\x0aHTTP/1.1 200 OK
393+
Server: ddos-guard
394+
Connection: keep-alive
395+
Keep-Alive: timeout=60
396+
Set-Cookie: __ddg1=z177j4mLtqzC07v0zviU; Domain=.site.ru; HttpOnly; Path=/; Expires=Wed, 07-Jul-2021 15:13:14 GMT
397+
Date: Tue, 07 Jul 2020 15:13:14 GMT
398+
Expires: Thu, 19 Nov 1981 08:52:00 GMT
399+
Cache-Control: no-store, no-cache, must-revalidate
400+
Pragma: no-cache
401+
Set-Cookie: PHPSESSID=80pd3hlg38mvjnelpvokp9lad0; path=/
402+
Content-Type: application/xml; charset=utf-8
403+
Transfer-Encoding: chunked\x0d\x0a\x0d\x0a<title>Update success! config</title>";
404404

405405
$this->request->setOutput($output);
406406

@@ -440,20 +440,20 @@ public function testSetAuthBasic(): void
440440
public function testSetAuthDigest(): void
441441
{
442442
$output = "HTTP/1.1 401 Unauthorized
443-
Server: ddos-guard
444-
Set-Cookie: __ddg1=z177j4mLtqzC07v0zviU; Domain=.site.ru; HttpOnly; Path=/; Expires=Wed, 07-Jul-2021 15:13:14 GMT
445-
WWW-Authenticate: Digest\x0d\x0a\x0d\x0aHTTP/1.1 200 OK
446-
Server: ddos-guard
447-
Connection: keep-alive
448-
Keep-Alive: timeout=60
449-
Set-Cookie: __ddg1=z177j4mLtqzC07v0zviU; Domain=.site.ru; HttpOnly; Path=/; Expires=Wed, 07-Jul-2021 15:13:14 GMT
450-
Date: Tue, 07 Jul 2020 15:13:14 GMT
451-
Expires: Thu, 19 Nov 1981 08:52:00 GMT
452-
Cache-Control: no-store, no-cache, must-revalidate
453-
Pragma: no-cache
454-
Set-Cookie: PHPSESSID=80pd3hlg38mvjnelpvokp9lad0; path=/
455-
Content-Type: application/xml; charset=utf-8
456-
Transfer-Encoding: chunked\x0d\x0a\x0d\x0a<title>Update success! config</title>";
443+
Server: ddos-guard
444+
Set-Cookie: __ddg1=z177j4mLtqzC07v0zviU; Domain=.site.ru; HttpOnly; Path=/; Expires=Wed, 07-Jul-2021 15:13:14 GMT
445+
WWW-Authenticate: Digest\x0d\x0a\x0d\x0aHTTP/1.1 200 OK
446+
Server: ddos-guard
447+
Connection: keep-alive
448+
Keep-Alive: timeout=60
449+
Set-Cookie: __ddg1=z177j4mLtqzC07v0zviU; Domain=.site.ru; HttpOnly; Path=/; Expires=Wed, 07-Jul-2021 15:13:14 GMT
450+
Date: Tue, 07 Jul 2020 15:13:14 GMT
451+
Expires: Thu, 19 Nov 1981 08:52:00 GMT
452+
Cache-Control: no-store, no-cache, must-revalidate
453+
Pragma: no-cache
454+
Set-Cookie: PHPSESSID=80pd3hlg38mvjnelpvokp9lad0; path=/
455+
Content-Type: application/xml; charset=utf-8
456+
Transfer-Encoding: chunked\x0d\x0a\x0d\x0a<title>Update success! config</title>";
457457

458458
$this->request->setOutput($output);
459459

0 commit comments

Comments
 (0)