summaryrefslogtreecommitdiff
path: root/Source/WebKit2/UIProcess/API/gtk/tests/TestResources.cpp
diff options
context:
space:
mode:
authorSimon Hausmann <simon.hausmann@nokia.com>2012-07-18 13:59:13 +0200
committerSimon Hausmann <simon.hausmann@nokia.com>2012-07-18 13:59:28 +0200
commit4d6084feccab99c0a7b3ecef26bb49c41dd50201 (patch)
treefd1195897f551eee6d5a15d07ff5733b15aa2a5c /Source/WebKit2/UIProcess/API/gtk/tests/TestResources.cpp
parentae901828d4689ab9e89113f6b6ea8042b37a9fda (diff)
downloadqtwebkit-4d6084feccab99c0a7b3ecef26bb49c41dd50201.tar.gz
Imported WebKit commit ff52235a78888e5cb8e286a828a8698042200e67 (http://svn.webkit.org/repository/webkit/trunk@122948)
New snapshot that should fix the rendering issues recently introduced
Diffstat (limited to 'Source/WebKit2/UIProcess/API/gtk/tests/TestResources.cpp')
-rw-r--r--Source/WebKit2/UIProcess/API/gtk/tests/TestResources.cpp34
1 files changed, 17 insertions, 17 deletions
diff --git a/Source/WebKit2/UIProcess/API/gtk/tests/TestResources.cpp b/Source/WebKit2/UIProcess/API/gtk/tests/TestResources.cpp
index 7de95e0f0..43f59e1e7 100644
--- a/Source/WebKit2/UIProcess/API/gtk/tests/TestResources.cpp
+++ b/Source/WebKit2/UIProcess/API/gtk/tests/TestResources.cpp
@@ -293,16 +293,16 @@ public:
m_loadEvents.append(Failed);
}
- void waitUntilResourceLoadFinsihed()
+ void waitUntilResourceLoadFinished()
{
m_resource = 0;
m_resourcesLoaded = 0;
g_main_loop_run(m_mainLoop);
}
- WebKitURIResponse* waitUntilResourceLoadFinsihedAndReturnURIResponse()
+ WebKitURIResponse* waitUntilResourceLoadFinishedAndReturnURIResponse()
{
- waitUntilResourceLoadFinsihed();
+ waitUntilResourceLoadFinished();
g_assert(m_resource);
return webkit_web_resource_get_response(m_resource.get());
}
@@ -315,7 +315,7 @@ public:
static void testWebResourceLoading(SingleResourceLoadTest* test, gconstpointer)
{
test->loadURI(kServer->getURIForPath("/javascript.html").data());
- test->waitUntilResourceLoadFinsihed();
+ test->waitUntilResourceLoadFinished();
g_assert(test->m_resource);
Vector<SingleResourceLoadTest::LoadEvents>& events = test->m_loadEvents;
g_assert_cmpint(events.size(), ==, 5);
@@ -327,7 +327,7 @@ static void testWebResourceLoading(SingleResourceLoadTest* test, gconstpointer)
events.clear();
test->loadURI(kServer->getURIForPath("/redirected-css.html").data());
- test->waitUntilResourceLoadFinsihed();
+ test->waitUntilResourceLoadFinished();
g_assert(test->m_resource);
g_assert_cmpint(events.size(), ==, 6);
g_assert_cmpint(events[0], ==, SingleResourceLoadTest::Started);
@@ -339,7 +339,7 @@ static void testWebResourceLoading(SingleResourceLoadTest* test, gconstpointer)
events.clear();
test->loadURI(kServer->getURIForPath("/invalid-css.html").data());
- test->waitUntilResourceLoadFinsihed();
+ test->waitUntilResourceLoadFinished();
g_assert(test->m_resource);
g_assert_cmpint(events.size(), ==, 4);
g_assert_cmpint(events[0], ==, SingleResourceLoadTest::Started);
@@ -353,47 +353,47 @@ static void testWebResourceResponse(SingleResourceLoadTest* test, gconstpointer)
{
// No cached resource: First load.
test->loadURI(kServer->getURIForPath("/javascript.html").data());
- WebKitURIResponse* response = test->waitUntilResourceLoadFinsihedAndReturnURIResponse();
+ WebKitURIResponse* response = test->waitUntilResourceLoadFinishedAndReturnURIResponse();
g_assert_cmpint(webkit_uri_response_get_status_code(response), ==, SOUP_STATUS_OK);
// No cached resource: Second load.
test->loadURI(kServer->getURIForPath("/javascript.html").data());
- response = test->waitUntilResourceLoadFinsihedAndReturnURIResponse();
+ response = test->waitUntilResourceLoadFinishedAndReturnURIResponse();
g_assert_cmpint(webkit_uri_response_get_status_code(response), ==, SOUP_STATUS_OK);
// No cached resource: Reload.
webkit_web_view_reload(test->m_webView);
- response = test->waitUntilResourceLoadFinsihedAndReturnURIResponse();
+ response = test->waitUntilResourceLoadFinishedAndReturnURIResponse();
g_assert_cmpint(webkit_uri_response_get_status_code(response), ==, SOUP_STATUS_OK);
// Cached resource: First load.
test->loadURI(kServer->getURIForPath("/image.html").data());
- response = test->waitUntilResourceLoadFinsihedAndReturnURIResponse();
+ response = test->waitUntilResourceLoadFinishedAndReturnURIResponse();
g_assert_cmpint(webkit_uri_response_get_status_code(response), ==, SOUP_STATUS_OK);
// Cached resource: Second load.
test->loadURI(kServer->getURIForPath("/image.html").data());
- response = test->waitUntilResourceLoadFinsihedAndReturnURIResponse();
+ response = test->waitUntilResourceLoadFinishedAndReturnURIResponse();
g_assert_cmpint(webkit_uri_response_get_status_code(response), ==, SOUP_STATUS_OK);
// Cached resource: Reload.
webkit_web_view_reload(test->m_webView);
- response = test->waitUntilResourceLoadFinsihedAndReturnURIResponse();
+ response = test->waitUntilResourceLoadFinishedAndReturnURIResponse();
g_assert_cmpint(webkit_uri_response_get_status_code(response), ==, SOUP_STATUS_NOT_MODIFIED);
}
static void testWebResourceMimeType(SingleResourceLoadTest* test, gconstpointer)
{
test->loadURI(kServer->getURIForPath("/javascript.html").data());
- WebKitURIResponse* response = test->waitUntilResourceLoadFinsihedAndReturnURIResponse();
+ WebKitURIResponse* response = test->waitUntilResourceLoadFinishedAndReturnURIResponse();
g_assert_cmpstr(webkit_uri_response_get_mime_type(response), ==, "text/javascript");
test->loadURI(kServer->getURIForPath("/image.html").data());
- response = test->waitUntilResourceLoadFinsihedAndReturnURIResponse();
+ response = test->waitUntilResourceLoadFinishedAndReturnURIResponse();
g_assert_cmpstr(webkit_uri_response_get_mime_type(response), ==, "image/vnd.microsoft.icon");
test->loadURI(kServer->getURIForPath("/redirected-css.html").data());
- response = test->waitUntilResourceLoadFinsihedAndReturnURIResponse();
+ response = test->waitUntilResourceLoadFinishedAndReturnURIResponse();
g_assert_cmpstr(webkit_uri_response_get_mime_type(response), ==, "text/css");
}
@@ -475,7 +475,7 @@ private:
static void testWebResourceActiveURI(ResourceURITrackingTest* test, gconstpointer)
{
test->loadURI(kServer->getURIForPath("/redirected-css.html").data());
- test->waitUntilResourceLoadFinsihed();
+ test->waitUntilResourceLoadFinished();
}
static void testWebResourceGetData(ResourcesTest* test, gconstpointer)
@@ -543,7 +543,7 @@ static void serverCallback(SoupServer* server, SoupMessage* message, const char*
soup_message_set_status(message, SOUP_STATUS_OK);
- if (soup_message_headers_get(message->request_headers, "If-Modified-Since")) {
+ if (soup_message_headers_get_one(message->request_headers, "If-Modified-Since")) {
soup_message_set_status(message, SOUP_STATUS_NOT_MODIFIED);
soup_message_body_complete(message->response_body);
return;