Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(323)

Side by Side Diff: third_party/WebKit/Source/web/tests/WebFrameTest.cpp

Issue 2469873002: [ImageResource 4] Split ImageResource into Resource and Image parts (Closed)
Patch Set: style Created 4 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « third_party/WebKit/Source/web/WebFrameSerializer.cpp ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2010 Google Inc. All rights reserved. 2 * Copyright (C) 2010 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 10042 matching lines...) Expand 10 before | Expand all | Expand 10 after
10053 registerMockedHttpURLLoadWithMimeType("white-1x1.png", "image/png"); 10053 registerMockedHttpURLLoadWithMimeType("white-1x1.png", "image/png");
10054 FrameTestHelpers::WebViewHelper webViewHelper; 10054 FrameTestHelpers::WebViewHelper webViewHelper;
10055 webViewHelper.initializeAndLoad(m_baseURL + "white-1x1.png"); 10055 webViewHelper.initializeAndLoad(m_baseURL + "white-1x1.png");
10056 WebViewImpl* webView = webViewHelper.webView(); 10056 WebViewImpl* webView = webViewHelper.webView();
10057 Document* document = webView->mainFrameImpl()->frame()->document(); 10057 Document* document = webView->mainFrameImpl()->frame()->document();
10058 10058
10059 EXPECT_TRUE(document); 10059 EXPECT_TRUE(document);
10060 EXPECT_TRUE(document->isImageDocument()); 10060 EXPECT_TRUE(document->isImageDocument());
10061 10061
10062 ImageDocument* imgDocument = toImageDocument(document); 10062 ImageDocument* imgDocument = toImageDocument(document);
10063 ImageResource* resource = imgDocument->cachedImage(); 10063 ImageResource* resource = imgDocument->cachedImageResourceDeprecated();
10064 10064
10065 EXPECT_TRUE(resource); 10065 EXPECT_TRUE(resource);
10066 EXPECT_NE(0, resource->loadFinishTime()); 10066 EXPECT_NE(0, resource->loadFinishTime());
10067 10067
10068 DocumentLoader* loader = document->loader(); 10068 DocumentLoader* loader = document->loader();
10069 10069
10070 EXPECT_TRUE(loader); 10070 EXPECT_TRUE(loader);
10071 EXPECT_EQ(loader->timing().responseEnd(), resource->loadFinishTime()); 10071 EXPECT_EQ(loader->timing().responseEnd(), resource->loadFinishTime());
10072 } 10072 }
10073 10073
(...skipping 1015 matching lines...) Expand 10 before | Expand all | Expand 10 after
11089 11089
11090 EXPECT_TRUE(mainFrameClient.childClient().didCallFrameDetached()); 11090 EXPECT_TRUE(mainFrameClient.childClient().didCallFrameDetached());
11091 EXPECT_TRUE(mainFrameClient.childClient().didCallDidStopLoading()); 11091 EXPECT_TRUE(mainFrameClient.childClient().didCallDidStopLoading());
11092 EXPECT_TRUE(mainFrameClient.childClient().didCallDidFinishDocumentLoad()); 11092 EXPECT_TRUE(mainFrameClient.childClient().didCallDidFinishDocumentLoad());
11093 EXPECT_TRUE(mainFrameClient.childClient().didCallDidHandleOnloadEvents()); 11093 EXPECT_TRUE(mainFrameClient.childClient().didCallDidHandleOnloadEvents());
11094 11094
11095 webViewHelper.reset(); 11095 webViewHelper.reset();
11096 } 11096 }
11097 11097
11098 } // namespace blink 11098 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/web/WebFrameSerializer.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698