WebKit Bugzilla
Attachment 346872 Details for
Bug 188455
: [LayoutTests] Suppress warning messages generated by the test scripts.
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
fix
188455.diff (text/plain), 4.70 KB, created by
Basuke Suzuki
on 2018-08-09 16:35:38 PDT
(
hide
)
Description:
fix
Filename:
MIME Type:
Creator:
Basuke Suzuki
Created:
2018-08-09 16:35:38 PDT
Size:
4.70 KB
patch
obsolete
>diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog >index fee10630bc8..6fc0d8368b6 100644 >--- a/LayoutTests/ChangeLog >+++ b/LayoutTests/ChangeLog >@@ -1,3 +1,18 @@ >+2018-08-09 Basuke Suzuki <Basuke.Suzuki@sony.com> >+ >+ [LayoutTests] Suppress warning messages generated by the test scripts. >+ https://bugs.webkit.org/show_bug.cgi?id=188455 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ The messages such as warnings shouldn't be out on error log if that can be avoidable. >+ >+ * http/tests/cookies/resources/cookie-utility.php: >+ * http/tests/xmlhttprequest/resources/access-control-allow-lists.php: >+ * http/tests/xmlhttprequest/resources/access-control-basic-get-fail-non-simple.cgi: >+ * http/tests/xmlhttprequest/resources/post-echo.cgi: >+ * http/tests/xmlhttprequest/web-apps/004-test.cgi: >+ > 2018-08-09 Miguel Gomez <magomez@igalia.com> > > Unreviewed GTK+ gardening after r234720. >diff --git a/LayoutTests/http/tests/cookies/resources/cookie-utility.php b/LayoutTests/http/tests/cookies/resources/cookie-utility.php >index 9f6e005fe2b..ed9a633d65f 100644 >--- a/LayoutTests/http/tests/cookies/resources/cookie-utility.php >+++ b/LayoutTests/http/tests/cookies/resources/cookie-utility.php >@@ -7,14 +7,14 @@ function deleteCookie($value, $name) > } > > if ($queryfunction == "deleteCookiesAndPostMessage") { >- array_walk($_COOKIE, deleteCookie); >+ array_walk($_COOKIE, 'deleteCookie'); > echo "<script>window.opener.postMessage('done', '*');</script>\n"; > return; > } > > > if ($queryfunction == "deleteCookies") { >- array_walk($_COOKIE, deleteCookie); >+ array_walk($_COOKIE, 'deleteCookie'); > echo "Deleted all cookies"; > return; > } >diff --git a/LayoutTests/http/tests/xmlhttprequest/resources/access-control-allow-lists.php b/LayoutTests/http/tests/xmlhttprequest/resources/access-control-allow-lists.php >index 8f0af5cf3ed..466049c52d4 100644 >--- a/LayoutTests/http/tests/xmlhttprequest/resources/access-control-allow-lists.php >+++ b/LayoutTests/http/tests/xmlhttprequest/resources/access-control-allow-lists.php >@@ -2,8 +2,10 @@ > > $origin = $_GET['origin']; > >-if ($origin != 'none') >- header("Access-Control-Allow-Origin: $origin"); >+if ($origin != 'none') { >+ // Supress warning when $origin intentionally contains \0 (null) byte in it. >+ @header("Access-Control-Allow-Origin: $origin"); >+} > > if (isset($_GET['headers'])) > header("Access-Control-Allow-Headers: {$_GET['headers']}"); >diff --git a/LayoutTests/http/tests/xmlhttprequest/resources/access-control-basic-get-fail-non-simple.cgi b/LayoutTests/http/tests/xmlhttprequest/resources/access-control-basic-get-fail-non-simple.cgi >index 5b0ea4c8f1e..955ab873d39 100755 >--- a/LayoutTests/http/tests/xmlhttprequest/resources/access-control-basic-get-fail-non-simple.cgi >+++ b/LayoutTests/http/tests/xmlhttprequest/resources/access-control-basic-get-fail-non-simple.cgi >@@ -8,4 +8,7 @@ if ($ENV{'REQUEST_METHOD'} eq "GET") { > print "Access-Control-Allow-Credentials: true\n"; > print "Access-Control-Allow-Origin: http://127.0.0.1:8000\n\n"; > print "FAIL: Cross-domain access allowed.\n"; >+} else { >+ # Generate internal server error politely. >+ print "Status: 500 Internal Server Error\n\n"; > } >diff --git a/LayoutTests/http/tests/xmlhttprequest/resources/post-echo.cgi b/LayoutTests/http/tests/xmlhttprequest/resources/post-echo.cgi >index fea9e126361..70565d2f5cc 100755 >--- a/LayoutTests/http/tests/xmlhttprequest/resources/post-echo.cgi >+++ b/LayoutTests/http/tests/xmlhttprequest/resources/post-echo.cgi >@@ -3,9 +3,11 @@ > print "Content-type: text/plain\n\n"; > > if ($ENV{'REQUEST_METHOD'} eq "POST") { >- read(STDIN, $request, $ENV{'CONTENT_LENGTH'}) >- || die "Could not get query\n"; >- print $request; >+ if ($ENV{'CONTENT_LENGTH'} > 0) { >+ read(STDIN, $request, $ENV{'CONTENT_LENGTH'}) >+ || die "Could not get query\n"; >+ print $request; >+ } > } else { > print "Wrong method: " . $ENV{'REQUEST_METHOD'} . "\n"; > } >diff --git a/LayoutTests/http/tests/xmlhttprequest/web-apps/004-test.cgi b/LayoutTests/http/tests/xmlhttprequest/web-apps/004-test.cgi >index 4db9ca12fe2..4f41900aa08 100755 >--- a/LayoutTests/http/tests/xmlhttprequest/web-apps/004-test.cgi >+++ b/LayoutTests/http/tests/xmlhttprequest/web-apps/004-test.cgi >@@ -1,4 +1,7 @@ > #!/usr/bin/perl -wT > use strict; > >-print "Content-Type: text/plain\nCache-Control: no-store\n\nRESULT:[$ENV{'HTTP_X_TEST_HEADER1'}][$ENV{'HTTP_X_TEST_HEADER2'}]"; >+my $val1 = exists($ENV{'HTTP_X_TEST_HEADER1'}) ? $ENV{'HTTP_X_TEST_HEADER1'} : ""; >+my $val2 = exists($ENV{'HTTP_X_TEST_HEADER2'}) ? $ENV{'HTTP_X_TEST_HEADER2'} : ""; >+ >+print "Content-Type: text/plain\nCache-Control: no-store\n\nRESULT:[${val1}][${val2}]";
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 188455
: 346872