Changeset 173254 in webkit


Ignore:
Timestamp:
Sep 4, 2014 12:03:54 AM (10 years ago)
Author:
commit-queue@webkit.org
Message:

XMLHttpRequest always defaults Content-Type to application/xml, while it should depend on data type
https://bugs.webkit.org/show_bug.cgi?id=11049

Patch by Youenn Fablet <youenn.fablet@crf.canon.fr> on 2014-09-03
Reviewed by Darin Adler.

Source/WebCore:

Updated default mime type when sending text (changed from application/xml to text/plain;charset=UTF-8)
Updated default mime type when sending document (set to application/xml;charset=UTF-8 for XML documents and text/html;charset=UTF-8 for HTML documents)

Test: http/tests/xmlhttprequest/post-content-type-document.html

  • xml/XMLHttpRequest.cpp:

(WebCore::XMLHttpRequest::send): updating default Content-Type valuess.

LayoutTests:

  • http/tests/xmlhttprequest/methods-lower-case-expected.txt: Rebaseline (application/xml -> text/plain;charset=UTF-8).
  • http/tests/xmlhttprequest/post-content-type-document.html: New test to cover default mime type for XML and HTML document data types.
  • http/tests/xmlhttprequest/post-content-type-document-expected.txt: Ditto.
  • http/tests/xmlhttprequest/post-content-type-expected.txt: Rebaseline (application/xml -> text/plain;charset=UTF-8).
  • http/tests/xmlhttprequest/post-content-type.html: Ditto.
  • http/tests/xmlhttprequest/request-encoding2.html: Ditto.
  • platform/gtk/http/tests/xmlhttprequest/methods-async-expected.txt: Ditto.
  • platform/gtk/http/tests/xmlhttprequest/methods-expected.txt: Ditto.
  • platform/gtk/http/tests/xmlhttprequest/workers/methods-async-expected.txt: Ditto.
  • platform/gtk/http/tests/xmlhttprequest/workers/methods-expected.txt: Ditto.
  • platform/gtk/http/tests/xmlhttprequest/workers/shared-worker-methods-async-expected.txt: Ditto.
  • platform/gtk/http/tests/xmlhttprequest/workers/shared-worker-methods-expected.txt: Ditto.
Location:
trunk
Files:
2 added
25 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r173250 r173254  
     12014-09-03  Youenn Fablet  <youenn.fablet@crf.canon.fr>
     2
     3        XMLHttpRequest always defaults Content-Type to application/xml, while it should depend on data type
     4        https://bugs.webkit.org/show_bug.cgi?id=11049
     5
     6        Reviewed by Darin Adler.
     7
     8        * http/tests/xmlhttprequest/methods-lower-case-expected.txt: Rebaseline (application/xml -> text/plain;charset=UTF-8).
     9        * http/tests/xmlhttprequest/post-content-type-document.html: New test to cover default mime type for XML and HTML document data types.
     10        * http/tests/xmlhttprequest/post-content-type-document-expected.txt: Ditto.
     11        * http/tests/xmlhttprequest/post-content-type-expected.txt: Rebaseline (application/xml -> text/plain;charset=UTF-8).
     12        * http/tests/xmlhttprequest/post-content-type.html: Ditto.
     13        * http/tests/xmlhttprequest/request-encoding2.html: Ditto.
     14        * platform/gtk/http/tests/xmlhttprequest/methods-async-expected.txt: Ditto.
     15        * platform/gtk/http/tests/xmlhttprequest/methods-expected.txt: Ditto.
     16        * platform/gtk/http/tests/xmlhttprequest/workers/methods-async-expected.txt: Ditto.
     17        * platform/gtk/http/tests/xmlhttprequest/workers/methods-expected.txt: Ditto.
     18        * platform/gtk/http/tests/xmlhttprequest/workers/shared-worker-methods-async-expected.txt: Ditto.
     19        * platform/gtk/http/tests/xmlhttprequest/workers/shared-worker-methods-expected.txt: Ditto.
     20
    1212014-09-03  Shivakumar JM  <shiva.jm@samsung.com>
    222
  • trunk/LayoutTests/http/tests/xmlhttprequest/methods-async-expected.txt

    • Property svn:executable set to *
    r21687 r173254  
    44GET(null): GET(null bytes), Content-Type: null
    55GET("123"): GET(null bytes), Content-Type: null
    6 POST(""): POST(0 bytes), Content-Type: application/xml
     6POST(""): POST(0 bytes), Content-Type: text/plain;charset=UTF-8
    77POST(null): POST(0 bytes), Content-Type: null
    8 POST("123"): POST(3 bytes), Content-Type: application/xml
    9 PUT(""): PUT(0 bytes), Content-Type: application/xml
     8POST("123"): POST(3 bytes), Content-Type: text/plain;charset=UTF-8
     9PUT(""): PUT(0 bytes), Content-Type: text/plain;charset=UTF-8
    1010PUT(null): PUT(0 bytes), Content-Type: null
    11 PUT("123"): PUT(3 bytes), Content-Type: application/xml
    12 DELETE(""): DELETE(0 bytes), Content-Type: application/xml
     11PUT("123"): PUT(3 bytes), Content-Type: text/plain;charset=UTF-8
     12DELETE(""): DELETE(0 bytes), Content-Type: text/plain;charset=UTF-8
    1313DELETE(null): DELETE(0 bytes), Content-Type: null
    14 DELETE("123"): DELETE(3 bytes), Content-Type: application/xml
     14DELETE("123"): DELETE(3 bytes), Content-Type: text/plain;charset=UTF-8
    1515HEAD(""): HEAD(0 bytes), Content-Type: null
    1616HEAD(null): HEAD(0 bytes), Content-Type: null
    1717HEAD("123"): HEAD(0 bytes), Content-Type: null
    18 WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: application/xml
     18WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: text/plain;charset=UTF-8
    1919WKFOOBAR(null): WKFOOBAR(0 bytes), Content-Type: null
    20 WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: application/xml
    21 SEARCH(""): SEARCH(0 bytes), Content-Type: application/xml
     20WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: text/plain;charset=UTF-8
     21SEARCH(""): SEARCH(0 bytes), Content-Type: text/plain;charset=UTF-8
    2222SEARCH(null): SEARCH(0 bytes), Content-Type: null
    23 SEARCH("123"): SEARCH(3 bytes), Content-Type: application/xml
     23SEARCH("123"): SEARCH(3 bytes), Content-Type: text/plain;charset=UTF-8
  • trunk/LayoutTests/http/tests/xmlhttprequest/methods-expected.txt

    • Property svn:executable set to *
    r21687 r173254  
    44GET(null): GET(null bytes), Content-Type: null
    55GET("123"): GET(null bytes), Content-Type: null
    6 POST(""): POST(0 bytes), Content-Type: application/xml
     6POST(""): POST(0 bytes), Content-Type: text/plain;charset=UTF-8
    77POST(null): POST(0 bytes), Content-Type: null
    8 POST("123"): POST(3 bytes), Content-Type: application/xml
    9 PUT(""): PUT(0 bytes), Content-Type: application/xml
     8POST("123"): POST(3 bytes), Content-Type: text/plain;charset=UTF-8
     9PUT(""): PUT(0 bytes), Content-Type: text/plain;charset=UTF-8
    1010PUT(null): PUT(0 bytes), Content-Type: null
    11 PUT("123"): PUT(3 bytes), Content-Type: application/xml
    12 DELETE(""): DELETE(0 bytes), Content-Type: application/xml
     11PUT("123"): PUT(3 bytes), Content-Type: text/plain;charset=UTF-8
     12DELETE(""): DELETE(0 bytes), Content-Type: text/plain;charset=UTF-8
    1313DELETE(null): DELETE(0 bytes), Content-Type: null
    14 DELETE("123"): DELETE(3 bytes), Content-Type: application/xml
     14DELETE("123"): DELETE(3 bytes), Content-Type: text/plain;charset=UTF-8
    1515HEAD(""): HEAD(0 bytes), Content-Type: null
    1616HEAD(null): HEAD(0 bytes), Content-Type: null
    1717HEAD("123"): HEAD(0 bytes), Content-Type: null
    18 WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: application/xml
     18WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: text/plain;charset=UTF-8
    1919WKFOOBAR(null): WKFOOBAR(0 bytes), Content-Type: null
    20 WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: application/xml
    21 SEARCH(""): SEARCH(0 bytes), Content-Type: application/xml
     20WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: text/plain;charset=UTF-8
     21SEARCH(""): SEARCH(0 bytes), Content-Type: text/plain;charset=UTF-8
    2222SEARCH(null): SEARCH(0 bytes), Content-Type: null
    23 SEARCH("123"): SEARCH(3 bytes), Content-Type: application/xml
     23SEARCH("123"): SEARCH(3 bytes), Content-Type: text/plain;charset=UTF-8
  • trunk/LayoutTests/http/tests/xmlhttprequest/methods-lower-case-expected.txt

    r21687 r173254  
    22
    33get(""): GET(null bytes), Content-Type: null
    4 post(""): POST(0 bytes), Content-Type: application/xml
    5 DoIt(""): DoIt(0 bytes), Content-Type: application/xml
     4post(""): POST(0 bytes), Content-Type: text/plain;charset=UTF-8
     5DoIt(""): DoIt(0 bytes), Content-Type: text/plain;charset=UTF-8
    66get(""): GET(null bytes), Content-Type: null
    7 post(""): POST(0 bytes), Content-Type: application/xml
    8 DoIt(""): DoIt(0 bytes), Content-Type: application/xml
     7post(""): POST(0 bytes), Content-Type: text/plain;charset=UTF-8
     8DoIt(""): DoIt(0 bytes), Content-Type: text/plain;charset=UTF-8
  • trunk/LayoutTests/http/tests/xmlhttprequest/post-content-type-expected.txt

    r12923 r173254  
    11Test for bug 3565 - posting data via XMLHttpRequest doesn't work (wrong Content-Type).
    22
    3 Should be application/xml:
     3Should be text/plain;charset=UTF-8:
    44
    5 application/xml
     5text/plain;charset=UTF-8
    66
  • trunk/LayoutTests/http/tests/xmlhttprequest/post-content-type.html

    r120167 r173254  
    33<p>Test for <a href="https://bugs.webkit.org/show_bug.cgi?id=3565">bug 3565</a>
    44- posting data via XMLHttpRequest doesn't work (wrong Content-Type).</p>
    5 <p>Should be application/xml:</p>
     5<p>Should be text/plain;charset=UTF-8:</p>
    66<script>
    77    if (window.testRunner)
  • trunk/LayoutTests/http/tests/xmlhttprequest/request-encoding2.html

    r120167 r173254  
    1919
    2020        document.getElementById("result1").firstChild.data = "Test1 (setRequestHeader was not called):";
    21         if (req.responseText == "application/xml\n")
     21        if (req.responseText == "text/plain;charset=UTF-8\n")
    2222            document.getElementById("result1").firstChild.data += " SUCCESS";
    2323        else
  • trunk/LayoutTests/http/tests/xmlhttprequest/workers/methods-async-expected.txt

    • Property svn:executable set to *
    r41344 r173254  
    44GET(null): GET(null bytes), Content-Type: null
    55GET("123"): GET(null bytes), Content-Type: null
    6 POST(""): POST(0 bytes), Content-Type: application/xml
     6POST(""): POST(0 bytes), Content-Type: text/plain;charset=UTF-8
    77POST(null): POST(0 bytes), Content-Type: null
    8 POST("123"): POST(3 bytes), Content-Type: application/xml
    9 PUT(""): PUT(0 bytes), Content-Type: application/xml
     8POST("123"): POST(3 bytes), Content-Type: text/plain;charset=UTF-8
     9PUT(""): PUT(0 bytes), Content-Type: text/plain;charset=UTF-8
    1010PUT(null): PUT(0 bytes), Content-Type: null
    11 PUT("123"): PUT(3 bytes), Content-Type: application/xml
    12 DELETE(""): DELETE(0 bytes), Content-Type: application/xml
     11PUT("123"): PUT(3 bytes), Content-Type: text/plain;charset=UTF-8
     12DELETE(""): DELETE(0 bytes), Content-Type: text/plain;charset=UTF-8
    1313DELETE(null): DELETE(0 bytes), Content-Type: null
    14 DELETE("123"): DELETE(3 bytes), Content-Type: application/xml
     14DELETE("123"): DELETE(3 bytes), Content-Type: text/plain;charset=UTF-8
    1515HEAD(""): HEAD(0 bytes), Content-Type: null
    1616HEAD(null): HEAD(0 bytes), Content-Type: null
    1717HEAD("123"): HEAD(0 bytes), Content-Type: null
    18 WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: application/xml
     18WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: text/plain;charset=UTF-8
    1919WKFOOBAR(null): WKFOOBAR(0 bytes), Content-Type: null
    20 WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: application/xml
    21 SEARCH(""): SEARCH(0 bytes), Content-Type: application/xml
     20WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: text/plain;charset=UTF-8
     21SEARCH(""): SEARCH(0 bytes), Content-Type: text/plain;charset=UTF-8
    2222SEARCH(null): SEARCH(0 bytes), Content-Type: null
    23 SEARCH("123"): SEARCH(3 bytes), Content-Type: application/xml
     23SEARCH("123"): SEARCH(3 bytes), Content-Type: text/plain;charset=UTF-8
    2424DONE
  • trunk/LayoutTests/http/tests/xmlhttprequest/workers/methods-expected.txt

    • Property svn:executable set to *
    r41344 r173254  
    44GET(null): GET(null bytes), Content-Type: null
    55GET("123"): GET(null bytes), Content-Type: null
    6 POST(""): POST(0 bytes), Content-Type: application/xml
     6POST(""): POST(0 bytes), Content-Type: text/plain;charset=UTF-8
    77POST(null): POST(0 bytes), Content-Type: null
    8 POST("123"): POST(3 bytes), Content-Type: application/xml
    9 PUT(""): PUT(0 bytes), Content-Type: application/xml
     8POST("123"): POST(3 bytes), Content-Type: text/plain;charset=UTF-8
     9PUT(""): PUT(0 bytes), Content-Type: text/plain;charset=UTF-8
    1010PUT(null): PUT(0 bytes), Content-Type: null
    11 PUT("123"): PUT(3 bytes), Content-Type: application/xml
    12 DELETE(""): DELETE(0 bytes), Content-Type: application/xml
     11PUT("123"): PUT(3 bytes), Content-Type: text/plain;charset=UTF-8
     12DELETE(""): DELETE(0 bytes), Content-Type: text/plain;charset=UTF-8
    1313DELETE(null): DELETE(0 bytes), Content-Type: null
    14 DELETE("123"): DELETE(3 bytes), Content-Type: application/xml
     14DELETE("123"): DELETE(3 bytes), Content-Type: text/plain;charset=UTF-8
    1515HEAD(""): HEAD(0 bytes), Content-Type: null
    1616HEAD(null): HEAD(0 bytes), Content-Type: null
    1717HEAD("123"): HEAD(0 bytes), Content-Type: null
    18 WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: application/xml
     18WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: text/plain;charset=UTF-8
    1919WKFOOBAR(null): WKFOOBAR(0 bytes), Content-Type: null
    20 WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: application/xml
    21 SEARCH(""): SEARCH(0 bytes), Content-Type: application/xml
     20WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: text/plain;charset=UTF-8
     21SEARCH(""): SEARCH(0 bytes), Content-Type: text/plain;charset=UTF-8
    2222SEARCH(null): SEARCH(0 bytes), Content-Type: null
    23 SEARCH("123"): SEARCH(3 bytes), Content-Type: application/xml
     23SEARCH("123"): SEARCH(3 bytes), Content-Type: text/plain;charset=UTF-8
    2424DONE
  • trunk/LayoutTests/http/tests/xmlhttprequest/workers/shared-worker-methods-async-expected.txt

    • Property svn:executable set to *
    r47467 r173254  
    44GET(null): GET(null bytes), Content-Type: null
    55GET("123"): GET(null bytes), Content-Type: null
    6 POST(""): POST(0 bytes), Content-Type: application/xml
     6POST(""): POST(0 bytes), Content-Type: text/plain;charset=UTF-8
    77POST(null): POST(0 bytes), Content-Type: null
    8 POST("123"): POST(3 bytes), Content-Type: application/xml
    9 PUT(""): PUT(0 bytes), Content-Type: application/xml
     8POST("123"): POST(3 bytes), Content-Type: text/plain;charset=UTF-8
     9PUT(""): PUT(0 bytes), Content-Type: text/plain;charset=UTF-8
    1010PUT(null): PUT(0 bytes), Content-Type: null
    11 PUT("123"): PUT(3 bytes), Content-Type: application/xml
    12 DELETE(""): DELETE(0 bytes), Content-Type: application/xml
     11PUT("123"): PUT(3 bytes), Content-Type: text/plain;charset=UTF-8
     12DELETE(""): DELETE(0 bytes), Content-Type: text/plain;charset=UTF-8
    1313DELETE(null): DELETE(0 bytes), Content-Type: null
    14 DELETE("123"): DELETE(3 bytes), Content-Type: application/xml
     14DELETE("123"): DELETE(3 bytes), Content-Type: text/plain;charset=UTF-8
    1515HEAD(""): HEAD(0 bytes), Content-Type: null
    1616HEAD(null): HEAD(0 bytes), Content-Type: null
    1717HEAD("123"): HEAD(0 bytes), Content-Type: null
    18 WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: application/xml
     18WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: text/plain;charset=UTF-8
    1919WKFOOBAR(null): WKFOOBAR(0 bytes), Content-Type: null
    20 WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: application/xml
    21 SEARCH(""): SEARCH(0 bytes), Content-Type: application/xml
     20WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: text/plain;charset=UTF-8
     21SEARCH(""): SEARCH(0 bytes), Content-Type: text/plain;charset=UTF-8
    2222SEARCH(null): SEARCH(0 bytes), Content-Type: null
    23 SEARCH("123"): SEARCH(3 bytes), Content-Type: application/xml
     23SEARCH("123"): SEARCH(3 bytes), Content-Type: text/plain;charset=UTF-8
    2424DONE
  • trunk/LayoutTests/http/tests/xmlhttprequest/workers/shared-worker-methods-expected.txt

    • Property svn:executable set to *
    r47467 r173254  
    44GET(null): GET(null bytes), Content-Type: null
    55GET("123"): GET(null bytes), Content-Type: null
    6 POST(""): POST(0 bytes), Content-Type: application/xml
     6POST(""): POST(0 bytes), Content-Type: text/plain;charset=UTF-8
    77POST(null): POST(0 bytes), Content-Type: null
    8 POST("123"): POST(3 bytes), Content-Type: application/xml
    9 PUT(""): PUT(0 bytes), Content-Type: application/xml
     8POST("123"): POST(3 bytes), Content-Type: text/plain;charset=UTF-8
     9PUT(""): PUT(0 bytes), Content-Type: text/plain;charset=UTF-8
    1010PUT(null): PUT(0 bytes), Content-Type: null
    11 PUT("123"): PUT(3 bytes), Content-Type: application/xml
    12 DELETE(""): DELETE(0 bytes), Content-Type: application/xml
     11PUT("123"): PUT(3 bytes), Content-Type: text/plain;charset=UTF-8
     12DELETE(""): DELETE(0 bytes), Content-Type: text/plain;charset=UTF-8
    1313DELETE(null): DELETE(0 bytes), Content-Type: null
    14 DELETE("123"): DELETE(3 bytes), Content-Type: application/xml
     14DELETE("123"): DELETE(3 bytes), Content-Type: text/plain;charset=UTF-8
    1515HEAD(""): HEAD(0 bytes), Content-Type: null
    1616HEAD(null): HEAD(0 bytes), Content-Type: null
    1717HEAD("123"): HEAD(0 bytes), Content-Type: null
    18 WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: application/xml
     18WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: text/plain;charset=UTF-8
    1919WKFOOBAR(null): WKFOOBAR(0 bytes), Content-Type: null
    20 WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: application/xml
    21 SEARCH(""): SEARCH(0 bytes), Content-Type: application/xml
     20WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: text/plain;charset=UTF-8
     21SEARCH(""): SEARCH(0 bytes), Content-Type: text/plain;charset=UTF-8
    2222SEARCH(null): SEARCH(0 bytes), Content-Type: null
    23 SEARCH("123"): SEARCH(3 bytes), Content-Type: application/xml
     23SEARCH("123"): SEARCH(3 bytes), Content-Type: text/plain;charset=UTF-8
    2424DONE
  • trunk/LayoutTests/platform/efl/http/tests/xmlhttprequest/methods-async-expected.txt

    r113019 r173254  
    44GET(null): GET(null bytes), Content-Type: null
    55GET("123"): GET(null bytes), Content-Type: null
    6 POST(""): POST(0 bytes), Content-Type: application/xml
     6POST(""): POST(0 bytes), Content-Type: text/plain;charset=UTF-8
    77POST(null): POST(0 bytes), Content-Type: null
    8 POST("123"): POST(3 bytes), Content-Type: application/xml
    9 PUT(""): PUT(0 bytes), Content-Type: application/xml
     8POST("123"): POST(3 bytes), Content-Type: text/plain;charset=UTF-8
     9PUT(""): PUT(0 bytes), Content-Type: text/plain;charset=UTF-8
    1010PUT(null): PUT(0 bytes), Content-Type: null
    11 PUT("123"): PUT(3 bytes), Content-Type: application/xml
    12 DELETE(""): DELETE(0 bytes), Content-Type: application/xml
     11PUT("123"): PUT(3 bytes), Content-Type: text/plain;charset=UTF-8
     12DELETE(""): DELETE(0 bytes), Content-Type: text/plain;charset=UTF-8
    1313DELETE(null): DELETE(null bytes), Content-Type: null
    14 DELETE("123"): DELETE(3 bytes), Content-Type: application/xml
     14DELETE("123"): DELETE(3 bytes), Content-Type: text/plain;charset=UTF-8
    1515HEAD(""): HEAD(null bytes), Content-Type: null
    1616HEAD(null): HEAD(null bytes), Content-Type: null
    1717HEAD("123"): HEAD(null bytes), Content-Type: null
    18 WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: application/xml
     18WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: text/plain;charset=UTF-8
    1919WKFOOBAR(null): WKFOOBAR(null bytes), Content-Type: null
    20 WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: application/xml
    21 SEARCH(""): SEARCH(0 bytes), Content-Type: application/xml
     20WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: text/plain;charset=UTF-8
     21SEARCH(""): SEARCH(0 bytes), Content-Type: text/plain;charset=UTF-8
    2222SEARCH(null): SEARCH(null bytes), Content-Type: null
    23 SEARCH("123"): SEARCH(3 bytes), Content-Type: application/xml
     23SEARCH("123"): SEARCH(3 bytes), Content-Type: text/plain;charset=UTF-8
  • trunk/LayoutTests/platform/efl/http/tests/xmlhttprequest/methods-expected.txt

    r113019 r173254  
    44GET(null): GET(null bytes), Content-Type: null
    55GET("123"): GET(null bytes), Content-Type: null
    6 POST(""): POST(0 bytes), Content-Type: application/xml
     6POST(""): POST(0 bytes), Content-Type: text/plain;charset=UTF-8
    77POST(null): POST(0 bytes), Content-Type: null
    8 POST("123"): POST(3 bytes), Content-Type: application/xml
    9 PUT(""): PUT(0 bytes), Content-Type: application/xml
     8POST("123"): POST(3 bytes), Content-Type: text/plain;charset=UTF-8
     9PUT(""): PUT(0 bytes), Content-Type: text/plain;charset=UTF-8
    1010PUT(null): PUT(0 bytes), Content-Type: null
    11 PUT("123"): PUT(3 bytes), Content-Type: application/xml
    12 DELETE(""): DELETE(0 bytes), Content-Type: application/xml
     11PUT("123"): PUT(3 bytes), Content-Type: text/plain;charset=UTF-8
     12DELETE(""): DELETE(0 bytes), Content-Type: text/plain;charset=UTF-8
    1313DELETE(null): DELETE(null bytes), Content-Type: null
    14 DELETE("123"): DELETE(3 bytes), Content-Type: application/xml
     14DELETE("123"): DELETE(3 bytes), Content-Type: text/plain;charset=UTF-8
    1515HEAD(""): HEAD(null bytes), Content-Type: null
    1616HEAD(null): HEAD(null bytes), Content-Type: null
    1717HEAD("123"): HEAD(null bytes), Content-Type: null
    18 WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: application/xml
     18WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: text/plain;charset=UTF-8
    1919WKFOOBAR(null): WKFOOBAR(null bytes), Content-Type: null
    20 WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: application/xml
    21 SEARCH(""): SEARCH(0 bytes), Content-Type: application/xml
     20WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: text/plain;charset=UTF-8
     21SEARCH(""): SEARCH(0 bytes), Content-Type: text/plain;charset=UTF-8
    2222SEARCH(null): SEARCH(null bytes), Content-Type: null
    23 SEARCH("123"): SEARCH(3 bytes), Content-Type: application/xml
     23SEARCH("123"): SEARCH(3 bytes), Content-Type: text/plain;charset=UTF-8
  • trunk/LayoutTests/platform/efl/http/tests/xmlhttprequest/workers/methods-async-expected.txt

    r113019 r173254  
    44GET(null): GET(null bytes), Content-Type: null
    55GET("123"): GET(null bytes), Content-Type: null
    6 POST(""): POST(0 bytes), Content-Type: application/xml
     6POST(""): POST(0 bytes), Content-Type: text/plain;charset=UTF-8
    77POST(null): POST(0 bytes), Content-Type: null
    8 POST("123"): POST(3 bytes), Content-Type: application/xml
    9 PUT(""): PUT(0 bytes), Content-Type: application/xml
     8POST("123"): POST(3 bytes), Content-Type: text/plain;charset=UTF-8
     9PUT(""): PUT(0 bytes), Content-Type: text/plain;charset=UTF-8
    1010PUT(null): PUT(0 bytes), Content-Type: null
    11 PUT("123"): PUT(3 bytes), Content-Type: application/xml
    12 DELETE(""): DELETE(0 bytes), Content-Type: application/xml
     11PUT("123"): PUT(3 bytes), Content-Type: text/plain;charset=UTF-8
     12DELETE(""): DELETE(0 bytes), Content-Type: text/plain;charset=UTF-8
    1313DELETE(null): DELETE(null bytes), Content-Type: null
    14 DELETE("123"): DELETE(3 bytes), Content-Type: application/xml
     14DELETE("123"): DELETE(3 bytes), Content-Type: text/plain;charset=UTF-8
    1515HEAD(""): HEAD(null bytes), Content-Type: null
    1616HEAD(null): HEAD(null bytes), Content-Type: null
    1717HEAD("123"): HEAD(null bytes), Content-Type: null
    18 WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: application/xml
     18WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: text/plain;charset=UTF-8
    1919WKFOOBAR(null): WKFOOBAR(null bytes), Content-Type: null
    20 WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: application/xml
    21 SEARCH(""): SEARCH(0 bytes), Content-Type: application/xml
     20WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: text/plain;charset=UTF-8
     21SEARCH(""): SEARCH(0 bytes), Content-Type: text/plain;charset=UTF-8
    2222SEARCH(null): SEARCH(null bytes), Content-Type: null
    23 SEARCH("123"): SEARCH(3 bytes), Content-Type: application/xml
     23SEARCH("123"): SEARCH(3 bytes), Content-Type: text/plain;charset=UTF-8
    2424DONE
  • trunk/LayoutTests/platform/efl/http/tests/xmlhttprequest/workers/methods-expected.txt

    r113019 r173254  
    44GET(null): GET(null bytes), Content-Type: null
    55GET("123"): GET(null bytes), Content-Type: null
    6 POST(""): POST(0 bytes), Content-Type: application/xml
     6POST(""): POST(0 bytes), Content-Type: text/plain;charset=UTF-8
    77POST(null): POST(0 bytes), Content-Type: null
    8 POST("123"): POST(3 bytes), Content-Type: application/xml
    9 PUT(""): PUT(0 bytes), Content-Type: application/xml
     8POST("123"): POST(3 bytes), Content-Type: text/plain;charset=UTF-8
     9PUT(""): PUT(0 bytes), Content-Type: text/plain;charset=UTF-8
    1010PUT(null): PUT(0 bytes), Content-Type: null
    11 PUT("123"): PUT(3 bytes), Content-Type: application/xml
    12 DELETE(""): DELETE(0 bytes), Content-Type: application/xml
     11PUT("123"): PUT(3 bytes), Content-Type: text/plain;charset=UTF-8
     12DELETE(""): DELETE(0 bytes), Content-Type: text/plain;charset=UTF-8
    1313DELETE(null): DELETE(null bytes), Content-Type: null
    14 DELETE("123"): DELETE(3 bytes), Content-Type: application/xml
     14DELETE("123"): DELETE(3 bytes), Content-Type: text/plain;charset=UTF-8
    1515HEAD(""): HEAD(null bytes), Content-Type: null
    1616HEAD(null): HEAD(null bytes), Content-Type: null
    1717HEAD("123"): HEAD(null bytes), Content-Type: null
    18 WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: application/xml
     18WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: text/plain;charset=UTF-8
    1919WKFOOBAR(null): WKFOOBAR(null bytes), Content-Type: null
    20 WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: application/xml
    21 SEARCH(""): SEARCH(0 bytes), Content-Type: application/xml
     20WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: text/plain;charset=UTF-8
     21SEARCH(""): SEARCH(0 bytes), Content-Type: text/plain;charset=UTF-8
    2222SEARCH(null): SEARCH(null bytes), Content-Type: null
    23 SEARCH("123"): SEARCH(3 bytes), Content-Type: application/xml
     23SEARCH("123"): SEARCH(3 bytes), Content-Type: text/plain;charset=UTF-8
    2424DONE
  • trunk/LayoutTests/platform/efl/http/tests/xmlhttprequest/workers/shared-worker-methods-async-expected.txt

    r113019 r173254  
    44GET(null): GET(null bytes), Content-Type: null
    55GET("123"): GET(null bytes), Content-Type: null
    6 POST(""): POST(0 bytes), Content-Type: application/xml
     6POST(""): POST(0 bytes), Content-Type: text/plain;charset=UTF-8
    77POST(null): POST(0 bytes), Content-Type: null
    8 POST("123"): POST(3 bytes), Content-Type: application/xml
    9 PUT(""): PUT(0 bytes), Content-Type: application/xml
     8POST("123"): POST(3 bytes), Content-Type: text/plain;charset=UTF-8
     9PUT(""): PUT(0 bytes), Content-Type: text/plain;charset=UTF-8
    1010PUT(null): PUT(0 bytes), Content-Type: null
    11 PUT("123"): PUT(3 bytes), Content-Type: application/xml
    12 DELETE(""): DELETE(0 bytes), Content-Type: application/xml
     11PUT("123"): PUT(3 bytes), Content-Type: text/plain;charset=UTF-8
     12DELETE(""): DELETE(0 bytes), Content-Type: text/plain;charset=UTF-8
    1313DELETE(null): DELETE(null bytes), Content-Type: null
    14 DELETE("123"): DELETE(3 bytes), Content-Type: application/xml
     14DELETE("123"): DELETE(3 bytes), Content-Type: text/plain;charset=UTF-8
    1515HEAD(""): HEAD(null bytes), Content-Type: null
    1616HEAD(null): HEAD(null bytes), Content-Type: null
    1717HEAD("123"): HEAD(null bytes), Content-Type: null
    18 WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: application/xml
     18WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: text/plain;charset=UTF-8
    1919WKFOOBAR(null): WKFOOBAR(null bytes), Content-Type: null
    20 WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: application/xml
    21 SEARCH(""): SEARCH(0 bytes), Content-Type: application/xml
     20WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: text/plain;charset=UTF-8
     21SEARCH(""): SEARCH(0 bytes), Content-Type: text/plain;charset=UTF-8
    2222SEARCH(null): SEARCH(null bytes), Content-Type: null
    23 SEARCH("123"): SEARCH(3 bytes), Content-Type: application/xml
     23SEARCH("123"): SEARCH(3 bytes), Content-Type: text/plain;charset=UTF-8
    2424DONE
  • trunk/LayoutTests/platform/efl/http/tests/xmlhttprequest/workers/shared-worker-methods-expected.txt

    r113019 r173254  
    44GET(null): GET(null bytes), Content-Type: null
    55GET("123"): GET(null bytes), Content-Type: null
    6 POST(""): POST(0 bytes), Content-Type: application/xml
     6POST(""): POST(0 bytes), Content-Type: text/plain;charset=UTF-8
    77POST(null): POST(0 bytes), Content-Type: null
    8 POST("123"): POST(3 bytes), Content-Type: application/xml
    9 PUT(""): PUT(0 bytes), Content-Type: application/xml
     8POST("123"): POST(3 bytes), Content-Type: text/plain;charset=UTF-8
     9PUT(""): PUT(0 bytes), Content-Type: text/plain;charset=UTF-8
    1010PUT(null): PUT(0 bytes), Content-Type: null
    11 PUT("123"): PUT(3 bytes), Content-Type: application/xml
    12 DELETE(""): DELETE(0 bytes), Content-Type: application/xml
     11PUT("123"): PUT(3 bytes), Content-Type: text/plain;charset=UTF-8
     12DELETE(""): DELETE(0 bytes), Content-Type: text/plain;charset=UTF-8
    1313DELETE(null): DELETE(null bytes), Content-Type: null
    14 DELETE("123"): DELETE(3 bytes), Content-Type: application/xml
     14DELETE("123"): DELETE(3 bytes), Content-Type: text/plain;charset=UTF-8
    1515HEAD(""): HEAD(null bytes), Content-Type: null
    1616HEAD(null): HEAD(null bytes), Content-Type: null
    1717HEAD("123"): HEAD(null bytes), Content-Type: null
    18 WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: application/xml
     18WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: text/plain;charset=UTF-8
    1919WKFOOBAR(null): WKFOOBAR(null bytes), Content-Type: null
    20 WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: application/xml
    21 SEARCH(""): SEARCH(0 bytes), Content-Type: application/xml
     20WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: text/plain;charset=UTF-8
     21SEARCH(""): SEARCH(0 bytes), Content-Type: text/plain;charset=UTF-8
    2222SEARCH(null): SEARCH(null bytes), Content-Type: null
    23 SEARCH("123"): SEARCH(3 bytes), Content-Type: application/xml
     23SEARCH("123"): SEARCH(3 bytes), Content-Type: text/plain;charset=UTF-8
    2424DONE
  • trunk/LayoutTests/platform/gtk/http/tests/xmlhttprequest/methods-async-expected.txt

    r113019 r173254  
    44GET(null): GET(null bytes), Content-Type: null
    55GET("123"): GET(null bytes), Content-Type: null
    6 POST(""): POST(0 bytes), Content-Type: application/xml
     6POST(""): POST(0 bytes), Content-Type: text/plain;charset=UTF-8
    77POST(null): POST(0 bytes), Content-Type: null
    8 POST("123"): POST(3 bytes), Content-Type: application/xml
    9 PUT(""): PUT(0 bytes), Content-Type: application/xml
     8POST("123"): POST(3 bytes), Content-Type: text/plain;charset=UTF-8
     9PUT(""): PUT(0 bytes), Content-Type: text/plain;charset=UTF-8
    1010PUT(null): PUT(0 bytes), Content-Type: null
    11 PUT("123"): PUT(3 bytes), Content-Type: application/xml
    12 DELETE(""): DELETE(0 bytes), Content-Type: application/xml
     11PUT("123"): PUT(3 bytes), Content-Type: text/plain;charset=UTF-8
     12DELETE(""): DELETE(0 bytes), Content-Type: text/plain;charset=UTF-8
    1313DELETE(null): DELETE(null bytes), Content-Type: null
    14 DELETE("123"): DELETE(3 bytes), Content-Type: application/xml
     14DELETE("123"): DELETE(3 bytes), Content-Type: text/plain;charset=UTF-8
    1515HEAD(""): HEAD(null bytes), Content-Type: null
    1616HEAD(null): HEAD(null bytes), Content-Type: null
    1717HEAD("123"): HEAD(null bytes), Content-Type: null
    18 WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: application/xml
     18WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: text/plain;charset=UTF-8
    1919WKFOOBAR(null): WKFOOBAR(null bytes), Content-Type: null
    20 WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: application/xml
    21 SEARCH(""): SEARCH(0 bytes), Content-Type: application/xml
     20WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: text/plain;charset=UTF-8
     21SEARCH(""): SEARCH(0 bytes), Content-Type: text/plain;charset=UTF-8
    2222SEARCH(null): SEARCH(null bytes), Content-Type: null
    23 SEARCH("123"): SEARCH(3 bytes), Content-Type: application/xml
     23SEARCH("123"): SEARCH(3 bytes), Content-Type: text/plain;charset=UTF-8
  • trunk/LayoutTests/platform/gtk/http/tests/xmlhttprequest/methods-expected.txt

    r113019 r173254  
    44GET(null): GET(null bytes), Content-Type: null
    55GET("123"): GET(null bytes), Content-Type: null
    6 POST(""): POST(0 bytes), Content-Type: application/xml
     6POST(""): POST(0 bytes), Content-Type: text/plain;charset=UTF-8
    77POST(null): POST(0 bytes), Content-Type: null
    8 POST("123"): POST(3 bytes), Content-Type: application/xml
    9 PUT(""): PUT(0 bytes), Content-Type: application/xml
     8POST("123"): POST(3 bytes), Content-Type: text/plain;charset=UTF-8
     9PUT(""): PUT(0 bytes), Content-Type: text/plain;charset=UTF-8
    1010PUT(null): PUT(0 bytes), Content-Type: null
    11 PUT("123"): PUT(3 bytes), Content-Type: application/xml
    12 DELETE(""): DELETE(0 bytes), Content-Type: application/xml
     11PUT("123"): PUT(3 bytes), Content-Type: text/plain;charset=UTF-8
     12DELETE(""): DELETE(0 bytes), Content-Type: text/plain;charset=UTF-8
    1313DELETE(null): DELETE(null bytes), Content-Type: null
    14 DELETE("123"): DELETE(3 bytes), Content-Type: application/xml
     14DELETE("123"): DELETE(3 bytes), Content-Type: text/plain;charset=UTF-8
    1515HEAD(""): HEAD(null bytes), Content-Type: null
    1616HEAD(null): HEAD(null bytes), Content-Type: null
    1717HEAD("123"): HEAD(null bytes), Content-Type: null
    18 WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: application/xml
     18WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: text/plain;charset=UTF-8
    1919WKFOOBAR(null): WKFOOBAR(null bytes), Content-Type: null
    20 WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: application/xml
    21 SEARCH(""): SEARCH(0 bytes), Content-Type: application/xml
     20WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: text/plain;charset=UTF-8
     21SEARCH(""): SEARCH(0 bytes), Content-Type: text/plain;charset=UTF-8
    2222SEARCH(null): SEARCH(null bytes), Content-Type: null
    23 SEARCH("123"): SEARCH(3 bytes), Content-Type: application/xml
     23SEARCH("123"): SEARCH(3 bytes), Content-Type: text/plain;charset=UTF-8
  • trunk/LayoutTests/platform/gtk/http/tests/xmlhttprequest/workers/methods-async-expected.txt

    r113019 r173254  
    44GET(null): GET(null bytes), Content-Type: null
    55GET("123"): GET(null bytes), Content-Type: null
    6 POST(""): POST(0 bytes), Content-Type: application/xml
     6POST(""): POST(0 bytes), Content-Type: text/plain;charset=UTF-8
    77POST(null): POST(0 bytes), Content-Type: null
    8 POST("123"): POST(3 bytes), Content-Type: application/xml
    9 PUT(""): PUT(0 bytes), Content-Type: application/xml
     8POST("123"): POST(3 bytes), Content-Type: text/plain;charset=UTF-8
     9PUT(""): PUT(0 bytes), Content-Type: text/plain;charset=UTF-8
    1010PUT(null): PUT(0 bytes), Content-Type: null
    11 PUT("123"): PUT(3 bytes), Content-Type: application/xml
    12 DELETE(""): DELETE(0 bytes), Content-Type: application/xml
     11PUT("123"): PUT(3 bytes), Content-Type: text/plain;charset=UTF-8
     12DELETE(""): DELETE(0 bytes), Content-Type: text/plain;charset=UTF-8
    1313DELETE(null): DELETE(null bytes), Content-Type: null
    14 DELETE("123"): DELETE(3 bytes), Content-Type: application/xml
     14DELETE("123"): DELETE(3 bytes), Content-Type: text/plain;charset=UTF-8
    1515HEAD(""): HEAD(null bytes), Content-Type: null
    1616HEAD(null): HEAD(null bytes), Content-Type: null
    1717HEAD("123"): HEAD(null bytes), Content-Type: null
    18 WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: application/xml
     18WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: text/plain;charset=UTF-8
    1919WKFOOBAR(null): WKFOOBAR(null bytes), Content-Type: null
    20 WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: application/xml
    21 SEARCH(""): SEARCH(0 bytes), Content-Type: application/xml
     20WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: text/plain;charset=UTF-8
     21SEARCH(""): SEARCH(0 bytes), Content-Type: text/plain;charset=UTF-8
    2222SEARCH(null): SEARCH(null bytes), Content-Type: null
    23 SEARCH("123"): SEARCH(3 bytes), Content-Type: application/xml
     23SEARCH("123"): SEARCH(3 bytes), Content-Type: text/plain;charset=UTF-8
    2424DONE
  • trunk/LayoutTests/platform/gtk/http/tests/xmlhttprequest/workers/methods-expected.txt

    r113019 r173254  
    44GET(null): GET(null bytes), Content-Type: null
    55GET("123"): GET(null bytes), Content-Type: null
    6 POST(""): POST(0 bytes), Content-Type: application/xml
     6POST(""): POST(0 bytes), Content-Type: text/plain;charset=UTF-8
    77POST(null): POST(0 bytes), Content-Type: null
    8 POST("123"): POST(3 bytes), Content-Type: application/xml
    9 PUT(""): PUT(0 bytes), Content-Type: application/xml
     8POST("123"): POST(3 bytes), Content-Type: text/plain;charset=UTF-8
     9PUT(""): PUT(0 bytes), Content-Type: text/plain;charset=UTF-8
    1010PUT(null): PUT(0 bytes), Content-Type: null
    11 PUT("123"): PUT(3 bytes), Content-Type: application/xml
    12 DELETE(""): DELETE(0 bytes), Content-Type: application/xml
     11PUT("123"): PUT(3 bytes), Content-Type: text/plain;charset=UTF-8
     12DELETE(""): DELETE(0 bytes), Content-Type: text/plain;charset=UTF-8
    1313DELETE(null): DELETE(null bytes), Content-Type: null
    14 DELETE("123"): DELETE(3 bytes), Content-Type: application/xml
     14DELETE("123"): DELETE(3 bytes), Content-Type: text/plain;charset=UTF-8
    1515HEAD(""): HEAD(null bytes), Content-Type: null
    1616HEAD(null): HEAD(null bytes), Content-Type: null
    1717HEAD("123"): HEAD(null bytes), Content-Type: null
    18 WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: application/xml
     18WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: text/plain;charset=UTF-8
    1919WKFOOBAR(null): WKFOOBAR(null bytes), Content-Type: null
    20 WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: application/xml
    21 SEARCH(""): SEARCH(0 bytes), Content-Type: application/xml
     20WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: text/plain;charset=UTF-8
     21SEARCH(""): SEARCH(0 bytes), Content-Type: text/plain;charset=UTF-8
    2222SEARCH(null): SEARCH(null bytes), Content-Type: null
    23 SEARCH("123"): SEARCH(3 bytes), Content-Type: application/xml
     23SEARCH("123"): SEARCH(3 bytes), Content-Type: text/plain;charset=UTF-8
    2424DONE
  • trunk/LayoutTests/platform/gtk/http/tests/xmlhttprequest/workers/shared-worker-methods-async-expected.txt

    r113019 r173254  
    44GET(null): GET(null bytes), Content-Type: null
    55GET("123"): GET(null bytes), Content-Type: null
    6 POST(""): POST(0 bytes), Content-Type: application/xml
     6POST(""): POST(0 bytes), Content-Type: text/plain;charset=UTF-8
    77POST(null): POST(0 bytes), Content-Type: null
    8 POST("123"): POST(3 bytes), Content-Type: application/xml
    9 PUT(""): PUT(0 bytes), Content-Type: application/xml
     8POST("123"): POST(3 bytes), Content-Type: text/plain;charset=UTF-8
     9PUT(""): PUT(0 bytes), Content-Type: text/plain;charset=UTF-8
    1010PUT(null): PUT(0 bytes), Content-Type: null
    11 PUT("123"): PUT(3 bytes), Content-Type: application/xml
    12 DELETE(""): DELETE(0 bytes), Content-Type: application/xml
     11PUT("123"): PUT(3 bytes), Content-Type: text/plain;charset=UTF-8
     12DELETE(""): DELETE(0 bytes), Content-Type: text/plain;charset=UTF-8
    1313DELETE(null): DELETE(null bytes), Content-Type: null
    14 DELETE("123"): DELETE(3 bytes), Content-Type: application/xml
     14DELETE("123"): DELETE(3 bytes), Content-Type: text/plain;charset=UTF-8
    1515HEAD(""): HEAD(null bytes), Content-Type: null
    1616HEAD(null): HEAD(null bytes), Content-Type: null
    1717HEAD("123"): HEAD(null bytes), Content-Type: null
    18 WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: application/xml
     18WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: text/plain;charset=UTF-8
    1919WKFOOBAR(null): WKFOOBAR(null bytes), Content-Type: null
    20 WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: application/xml
    21 SEARCH(""): SEARCH(0 bytes), Content-Type: application/xml
     20WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: text/plain;charset=UTF-8
     21SEARCH(""): SEARCH(0 bytes), Content-Type: text/plain;charset=UTF-8
    2222SEARCH(null): SEARCH(null bytes), Content-Type: null
    23 SEARCH("123"): SEARCH(3 bytes), Content-Type: application/xml
     23SEARCH("123"): SEARCH(3 bytes), Content-Type: text/plain;charset=UTF-8
    2424DONE
  • trunk/LayoutTests/platform/gtk/http/tests/xmlhttprequest/workers/shared-worker-methods-expected.txt

    r113019 r173254  
    44GET(null): GET(null bytes), Content-Type: null
    55GET("123"): GET(null bytes), Content-Type: null
    6 POST(""): POST(0 bytes), Content-Type: application/xml
     6POST(""): POST(0 bytes), Content-Type: text/plain;charset=UTF-8
    77POST(null): POST(0 bytes), Content-Type: null
    8 POST("123"): POST(3 bytes), Content-Type: application/xml
    9 PUT(""): PUT(0 bytes), Content-Type: application/xml
     8POST("123"): POST(3 bytes), Content-Type: text/plain;charset=UTF-8
     9PUT(""): PUT(0 bytes), Content-Type: text/plain;charset=UTF-8
    1010PUT(null): PUT(0 bytes), Content-Type: null
    11 PUT("123"): PUT(3 bytes), Content-Type: application/xml
    12 DELETE(""): DELETE(0 bytes), Content-Type: application/xml
     11PUT("123"): PUT(3 bytes), Content-Type: text/plain;charset=UTF-8
     12DELETE(""): DELETE(0 bytes), Content-Type: text/plain;charset=UTF-8
    1313DELETE(null): DELETE(null bytes), Content-Type: null
    14 DELETE("123"): DELETE(3 bytes), Content-Type: application/xml
     14DELETE("123"): DELETE(3 bytes), Content-Type: text/plain;charset=UTF-8
    1515HEAD(""): HEAD(null bytes), Content-Type: null
    1616HEAD(null): HEAD(null bytes), Content-Type: null
    1717HEAD("123"): HEAD(null bytes), Content-Type: null
    18 WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: application/xml
     18WKFOOBAR(""): WKFOOBAR(0 bytes), Content-Type: text/plain;charset=UTF-8
    1919WKFOOBAR(null): WKFOOBAR(null bytes), Content-Type: null
    20 WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: application/xml
    21 SEARCH(""): SEARCH(0 bytes), Content-Type: application/xml
     20WKFOOBAR("123"): WKFOOBAR(3 bytes), Content-Type: text/plain;charset=UTF-8
     21SEARCH(""): SEARCH(0 bytes), Content-Type: text/plain;charset=UTF-8
    2222SEARCH(null): SEARCH(null bytes), Content-Type: null
    23 SEARCH("123"): SEARCH(3 bytes), Content-Type: application/xml
     23SEARCH("123"): SEARCH(3 bytes), Content-Type: text/plain;charset=UTF-8
    2424DONE
  • trunk/Source/WebCore/ChangeLog

    r173251 r173254  
     12014-09-03  Youenn Fablet  <youenn.fablet@crf.canon.fr>
     2
     3        XMLHttpRequest always defaults Content-Type to application/xml, while it should depend on data type
     4        https://bugs.webkit.org/show_bug.cgi?id=11049
     5
     6        Reviewed by Darin Adler.
     7
     8        Updated default mime type when sending text (changed from application/xml to text/plain;charset=UTF-8)
     9        Updated default mime type when sending document (set to application/xml;charset=UTF-8 for XML documents and text/html;charset=UTF-8 for HTML documents)
     10
     11        Test: http/tests/xmlhttprequest/post-content-type-document.html
     12
     13        * xml/XMLHttpRequest.cpp:
     14        (WebCore::XMLHttpRequest::send): updating default Content-Type valuess.
     15
    1162014-09-02  Brian J. Burg  <burg@cs.washington.edu>
    217
  • trunk/Source/WebCore/xml/XMLHttpRequest.cpp

    r170960 r173254  
    594594#endif
    595595                // FIXME: this should include the charset used for encoding.
    596                 setRequestHeaderInternal("Content-Type", "application/xml");
     596                setRequestHeaderInternal("Content-Type", document->isHTMLDocument() ? "text/html;charset=UTF-8":"application/xml;charset=UTF-8");
    597597        }
    598598
     
    601601        String body = createMarkup(*document);
    602602
    603         // FIXME: this should use value of document.inputEncoding to determine the encoding to use.
    604         TextEncoding encoding = UTF8Encoding();
    605         m_requestEntityBody = FormData::create(encoding.encode(body, EntitiesForUnencodables));
     603        m_requestEntityBody = FormData::create(UTF8Encoding().encode(body, EntitiesForUnencodables));
    606604        if (m_upload)
    607605            m_requestEntityBody->setAlwaysStream(true);
     
    624622            else
    625623#endif
    626                 setRequestHeaderInternal("Content-Type", "application/xml");
     624                setRequestHeaderInternal("Content-Type", "text/plain;charset=UTF-8");
    627625        } else {
    628626            replaceCharsetInMediaType(contentType, "UTF-8");
Note: See TracChangeset for help on using the changeset viewer.