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

Side by Side Diff: Source/platform/graphics/paint/DisplayItemTest.cpp

Issue 1306433002: Let collapsed border drawings be cacheable (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 4 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
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 "config.h" 5 #include "config.h"
6 #include "platform/graphics/paint/DisplayItem.h" 6 #include "platform/graphics/paint/DisplayItem.h"
7 7
8 #include <gtest/gtest.h> 8 #include <gtest/gtest.h>
9 9
10 namespace blink { 10 namespace blink {
11 namespace { 11 namespace {
12 12
13 #ifndef NDEBUG 13 #ifndef NDEBUG
14 TEST(DisplayItemTest, DebugStringsExist) 14 TEST(DisplayItemTest, DebugStringsExist)
15 { 15 {
16 for (int type = 0; type <= DisplayItem::TypeLast; type++) { 16 for (int type = 0; type <= DisplayItem::TypeLast; type++) {
17 DisplayItem::Type nonCachedType = DisplayItem::nonCachedType(static_cast <DisplayItem::Type>(type));
pdr. 2015/08/21 00:08:22 Can we remove the special case for collapsed borde
Xianzhu 2015/08/21 17:11:52 Done.
18 if (nonCachedType >= DisplayItem::TableCollapsedBorderUnalignedBase && n onCachedType <= DisplayItem::TableCollapsedBorderBase)
19 continue;
20
17 String debugString = DisplayItem::typeAsDebugString(static_cast<DisplayI tem::Type>(type)); 21 String debugString = DisplayItem::typeAsDebugString(static_cast<DisplayI tem::Type>(type));
18 EXPECT_FALSE(debugString.isEmpty()); 22 EXPECT_FALSE(debugString.isEmpty());
19 EXPECT_NE("Unknown", debugString); 23 EXPECT_NE("Unknown", debugString);
20 } 24 }
21 } 25 }
22 #endif // NDEBUG 26 #endif // NDEBUG
23 27
24 } // namespace 28 } // namespace
25 } // namespace blink 29 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698