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

Unified Diff: third_party/WebKit/Source/core/frame/ImageBitmapTest.cpp

Issue 2864253003: Split ImageLoader::SetImage() and set flags consistently in tests (Closed)
Patch Set: Update comment Created 3 years, 7 months 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/html/HTMLImageElement.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/frame/ImageBitmapTest.cpp
diff --git a/third_party/WebKit/Source/core/frame/ImageBitmapTest.cpp b/third_party/WebKit/Source/core/frame/ImageBitmapTest.cpp
index 977ae0096e3737ae141063d3ed15c8136ce4a947..30265b361d74bcf5caa140bc6aa76ea2400e9193 100644
--- a/third_party/WebKit/Source/core/frame/ImageBitmapTest.cpp
+++ b/third_party/WebKit/Source/core/frame/ImageBitmapTest.cpp
@@ -108,7 +108,7 @@ TEST_F(ImageBitmapTest, ImageResourceConsistency) {
HTMLImageElement::Create(*Document::Create());
ImageResourceContent* image = ImageResourceContent::CreateLoaded(
StaticBitmapImage::Create(image_).Get());
- image_element->SetImageResource(image);
+ image_element->SetImageForTest(image);
Optional<IntRect> crop_rect =
IntRect(0, 0, image_->width(), image_->height());
@@ -151,7 +151,7 @@ TEST_F(ImageBitmapTest, ImageBitmapSourceChanged) {
ImageResourceContent* original_image_resource =
ImageResourceContent::CreateLoaded(
StaticBitmapImage::Create(image_).Get());
- image->SetImageResource(original_image_resource);
+ image->SetImageForTest(original_image_resource);
const ImageBitmapOptions default_options;
Optional<IntRect> crop_rect =
@@ -166,7 +166,7 @@ TEST_F(ImageBitmapTest, ImageBitmapSourceChanged) {
ImageResourceContent* new_image_resource = ImageResourceContent::CreateLoaded(
StaticBitmapImage::Create(image2_).Get());
- image->SetImageResource(new_image_resource);
+ image->SetImageForTest(new_image_resource);
{
ASSERT_NE(image_bitmap->BitmapImage()->ImageForCurrentFrame(),
@@ -244,7 +244,7 @@ TEST_F(ImageBitmapTest, ImageBitmapColorSpaceConversionHTMLImageElement) {
ImageResourceContent* original_image_resource =
ImageResourceContent::CreateLoaded(
StaticBitmapImage::Create(image).Get());
- image_element->SetImageResource(original_image_resource);
+ image_element->SetImageForTest(original_image_resource);
Optional<IntRect> crop_rect = IntRect(0, 0, image->width(), image->height());
@@ -356,7 +356,7 @@ TEST_F(ImageBitmapTest, ImageBitmapColorSpaceConversionImageBitmap) {
ImageResourceContent* source_image_resource =
ImageResourceContent::CreateLoaded(
StaticBitmapImage::Create(image).Get());
- image_element->SetImageResource(source_image_resource);
+ image_element->SetImageForTest(source_image_resource);
Optional<IntRect> crop_rect = IntRect(0, 0, image->width(), image->height());
ImageBitmapOptions options =
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/html/HTMLImageElement.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698