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

Side by Side Diff: Source/web/tests/WebViewTest.cpp

Issue 1129173006: Enable slimming paint by default (for trybots only) (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Tue Jun 9 10:33:43 PDT 2015 Created 5 years, 6 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 /* 1 /*
2 * Copyright (C) 2011, 2012 Google Inc. All rights reserved. 2 * Copyright (C) 2011, 2012 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 488 matching lines...) Expand 10 before | Expand all | Expand 10 after
499 EXPECT_NE(kBlue, webView->backgroundColor()); 499 EXPECT_NE(kBlue, webView->backgroundColor());
500 // webView does not have a frame yet, but we should still be able to set the background color. 500 // webView does not have a frame yet, but we should still be able to set the background color.
501 webView->setBaseBackgroundColor(kBlue); 501 webView->setBaseBackgroundColor(kBlue);
502 EXPECT_EQ(kBlue, webView->backgroundColor()); 502 EXPECT_EQ(kBlue, webView->backgroundColor());
503 WebLocalFrameImpl* frame = WebLocalFrameImpl::create(WebTreeScopeType::Docum ent, nullptr); 503 WebLocalFrameImpl* frame = WebLocalFrameImpl::create(WebTreeScopeType::Docum ent, nullptr);
504 webView->setMainFrame(frame); 504 webView->setMainFrame(frame);
505 webView->close(); 505 webView->close();
506 frame->close(); 506 frame->close();
507 } 507 }
508 508
509 TEST_F(WebViewTest, SetBaseBackgroundColorAndBlendWithExistingContent) 509 TEST_F(WebViewTest, DISABLED_SetBaseBackgroundColorAndBlendWithExistingContent)
wkorman 2015/06/09 23:31:06 Do you remember what prompted need to disable this
Xianzhu 2015/06/09 23:52:19 Perhaps because of incompatible painting method at
510 { 510 {
511 const WebColor kAlphaRed = 0x80FF0000; 511 const WebColor kAlphaRed = 0x80FF0000;
512 const WebColor kAlphaGreen = 0x8000FF00; 512 const WebColor kAlphaGreen = 0x8000FF00;
513 const int kWidth = 100; 513 const int kWidth = 100;
514 const int kHeight = 100; 514 const int kHeight = 100;
515 515
516 WebView* webView = m_webViewHelper.initialize(); 516 WebView* webView = m_webViewHelper.initialize();
517 517
518 // Set WebView background to green with alpha. 518 // Set WebView background to green with alpha.
519 webView->setBaseBackgroundColor(kAlphaGreen); 519 webView->setBaseBackgroundColor(kAlphaGreen);
(...skipping 2524 matching lines...) Expand 10 before | Expand all | Expand 10 after
3044 for (size_t i = 0; i < renders.size(); ++i) { 3044 for (size_t i = 0; i < renders.size(); ++i) {
3045 double docStartTime = frame->domWindow()->document()->loader()->timing() .monotonicTimeToZeroBasedDocumentTime(renderPairs[i].startTime) * 1000.0; 3045 double docStartTime = frame->domWindow()->document()->loader()->timing() .monotonicTimeToZeroBasedDocumentTime(renderPairs[i].startTime) * 1000.0;
3046 ASSERT_DOUBLE_EQ(docStartTime, renders[i]->startTime()); 3046 ASSERT_DOUBLE_EQ(docStartTime, renders[i]->startTime());
3047 double docFinishTime = frame->domWindow()->document()->loader()->timing( ).monotonicTimeToZeroBasedDocumentTime(renderPairs[i].finishTime) * 1000.0; 3047 double docFinishTime = frame->domWindow()->document()->loader()->timing( ).monotonicTimeToZeroBasedDocumentTime(renderPairs[i].finishTime) * 1000.0;
3048 double docDuration = docFinishTime - docStartTime; 3048 double docDuration = docFinishTime - docStartTime;
3049 ASSERT_DOUBLE_EQ(docDuration, renders[i]->duration()); 3049 ASSERT_DOUBLE_EQ(docDuration, renders[i]->duration());
3050 } 3050 }
3051 } 3051 }
3052 3052
3053 } // namespace 3053 } // namespace
OLDNEW
« no previous file with comments | « Source/platform/graphics/paint/DisplayItemListTest.cpp ('k') | Tools/Scripts/webkitpy/layout_tests/run_webkit_tests.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698