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

Side by Side Diff: skia/ext/skia_utils_mac_unittest.mm

Issue 10828036: Reenables previously failing tests in SkiaUtilsMacTest.* (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 5 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | 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 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "skia/ext/skia_utils_mac.mm" 5 #include "skia/ext/skia_utils_mac.mm"
6 #include "testing/gtest/include/gtest/gtest.h" 6 #include "testing/gtest/include/gtest/gtest.h"
7 7
8 namespace { 8 namespace {
9 9
10 class SkiaUtilsMacTest : public testing::Test { 10 class SkiaUtilsMacTest : public testing::Test {
(...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after
168 NSImage* image = gfx::SkBitmapToNSImage(thing); 168 NSImage* image = gfx::SkBitmapToNSImage(thing);
169 EXPECT_DOUBLE_EQ([image size].width, (double)width); 169 EXPECT_DOUBLE_EQ([image size].width, (double)width);
170 EXPECT_DOUBLE_EQ([image size].height, (double)height); 170 EXPECT_DOUBLE_EQ([image size].height, (double)height);
171 171
172 EXPECT_TRUE([[image representations] count] == 1); 172 EXPECT_TRUE([[image representations] count] == 1);
173 EXPECT_TRUE([[[image representations] lastObject] 173 EXPECT_TRUE([[[image representations] lastObject]
174 isKindOfClass:[NSBitmapImageRep class]]); 174 isKindOfClass:[NSBitmapImageRep class]]);
175 TestImageRep([[image representations] lastObject], isred); 175 TestImageRep([[image representations] lastObject], isred);
176 } 176 }
177 177
178 TEST_F(SkiaUtilsMacTest, FAILS_BitmapToNSImage_RedSquare64x64) { 178 TEST_F(SkiaUtilsMacTest, BitmapToNSImage_RedSquare64x64) {
179 ShapeHelper(64, 64, true, true); 179 ShapeHelper(64, 64, true, true);
180 } 180 }
181 181
182 TEST_F(SkiaUtilsMacTest, BitmapToNSImage_BlueRectangle199x19) { 182 TEST_F(SkiaUtilsMacTest, BitmapToNSImage_BlueRectangle199x19) {
183 ShapeHelper(199, 19, false, true); 183 ShapeHelper(199, 19, false, true);
184 } 184 }
185 185
186 TEST_F(SkiaUtilsMacTest, FAILS_BitmapToNSImage_BlueRectangle444) { 186 TEST_F(SkiaUtilsMacTest, BitmapToNSImage_BlueRectangle444) {
187 ShapeHelper(200, 200, false, false); 187 ShapeHelper(200, 200, false, false);
188 } 188 }
189 189
190 TEST_F(SkiaUtilsMacTest, FAILS_BitmapToNSBitmapImageRep_BlueRectangle20x30) { 190 TEST_F(SkiaUtilsMacTest, BitmapToNSBitmapImageRep_BlueRectangle20x30) {
191 int width = 20; 191 int width = 20;
192 int height = 30; 192 int height = 30;
193 193
194 SkBitmap bitmap(CreateSkBitmap(width, height, false, true)); 194 SkBitmap bitmap(CreateSkBitmap(width, height, false, true));
195 NSBitmapImageRep* imageRep = gfx::SkBitmapToNSBitmapImageRep(bitmap); 195 NSBitmapImageRep* imageRep = gfx::SkBitmapToNSBitmapImageRep(bitmap);
196 196
197 EXPECT_DOUBLE_EQ(width, [imageRep size].width); 197 EXPECT_DOUBLE_EQ(width, [imageRep size].width);
198 EXPECT_DOUBLE_EQ(height, [imageRep size].height); 198 EXPECT_DOUBLE_EQ(height, [imageRep size].height);
199 TestImageRep(imageRep, false); 199 TestImageRep(imageRep, false);
200 } 200 }
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
238 TEST_F(SkiaUtilsMacTest, BitLocker_ClipNoBits) { 238 TEST_F(SkiaUtilsMacTest, BitLocker_ClipNoBits) {
239 RunBitLockerTest(SkiaUtilsMacTest::TestClipNoBits); 239 RunBitLockerTest(SkiaUtilsMacTest::TestClipNoBits);
240 } 240 }
241 241
242 TEST_F(SkiaUtilsMacTest, BitLocker_XClipNoBits) { 242 TEST_F(SkiaUtilsMacTest, BitLocker_XClipNoBits) {
243 RunBitLockerTest(SkiaUtilsMacTest::TestXClipNoBits); 243 RunBitLockerTest(SkiaUtilsMacTest::TestXClipNoBits);
244 } 244 }
245 245
246 } // namespace 246 } // namespace
247 247
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698