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

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

Issue 2691583003: Removed fields from Selection classes (Closed)
Patch Set: Forgot to remove fields from test Created 3 years, 10 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
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 5759 matching lines...) Expand 10 before | Expand all | Expand 10 after
5770 if (expectedResult.Length() == 13) 5770 if (expectedResult.Length() == 13)
5771 yBottomEpsilon = expectedResult.Get(context, 12) 5771 yBottomEpsilon = expectedResult.Get(context, 12)
5772 .ToLocalChecked() 5772 .ToLocalChecked()
5773 .As<v8::Int32>() 5773 .As<v8::Int32>()
5774 ->Value(); 5774 ->Value();
5775 int yBottomDeviation = 5775 int yBottomDeviation =
5776 startEdgeBottomInLayerY - selectStart->edgeBottomInLayer.y; 5776 startEdgeBottomInLayerY - selectStart->edgeBottomInLayer.y;
5777 EXPECT_GE(yBottomEpsilon, std::abs(yBottomDeviation)); 5777 EXPECT_GE(yBottomEpsilon, std::abs(yBottomDeviation));
5778 EXPECT_EQ(yBottomDeviation, 5778 EXPECT_EQ(yBottomDeviation,
5779 endEdgeBottomInLayerY - selectEnd->edgeBottomInLayer.y); 5779 endEdgeBottomInLayerY - selectEnd->edgeBottomInLayer.y);
5780
5781 if (expectedResult.Length() >= 12) {
5782 EXPECT_EQ(expectedResult.Get(context, 10)
5783 .ToLocalChecked()
5784 .As<v8::Boolean>()
5785 ->Value(),
5786 m_fakeSelectionLayerTreeView.selection()->isEditable());
5787 EXPECT_EQ(
5788 expectedResult.Get(context, 11)
5789 .ToLocalChecked()
5790 .As<v8::Boolean>()
5791 ->Value(),
5792 m_fakeSelectionLayerTreeView.selection()->isEmptyTextFormControl());
5793 }
5794 } 5780 }
5795 5781
5796 void runTestWithMultipleFiles(const char* testFile, ...) { 5782 void runTestWithMultipleFiles(const char* testFile, ...) {
5797 va_list auxFiles; 5783 va_list auxFiles;
5798 va_start(auxFiles, testFile); 5784 va_start(auxFiles, testFile);
5799 while (const char* auxFile = va_arg(auxFiles, const char*)) 5785 while (const char* auxFile = va_arg(auxFiles, const char*))
5800 registerMockedHttpURLLoad(auxFile); 5786 registerMockedHttpURLLoad(auxFile);
5801 va_end(auxFiles); 5787 va_end(auxFiles);
5802 5788
5803 runTest(testFile); 5789 runTest(testFile);
(...skipping 5583 matching lines...) Expand 10 before | Expand all | Expand 10 after
11387 11373
11388 EXPECT_TRUE(mainFrameClient.childClient().didCallFrameDetached()); 11374 EXPECT_TRUE(mainFrameClient.childClient().didCallFrameDetached());
11389 EXPECT_TRUE(mainFrameClient.childClient().didCallDidStopLoading()); 11375 EXPECT_TRUE(mainFrameClient.childClient().didCallDidStopLoading());
11390 EXPECT_TRUE(mainFrameClient.childClient().didCallDidFinishDocumentLoad()); 11376 EXPECT_TRUE(mainFrameClient.childClient().didCallDidFinishDocumentLoad());
11391 EXPECT_TRUE(mainFrameClient.childClient().didCallDidHandleOnloadEvents()); 11377 EXPECT_TRUE(mainFrameClient.childClient().didCallDidHandleOnloadEvents());
11392 11378
11393 webViewHelper.reset(); 11379 webViewHelper.reset();
11394 } 11380 }
11395 11381
11396 } // namespace blink 11382 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/web/WebSelection.cpp ('k') | third_party/WebKit/public/web/WebSelection.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698