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

Unified Diff: third_party/WebKit/Source/web/tests/VisualViewportTest.cpp

Issue 2154493002: FrameTestHelpers: support Settings-parameterized tests. (Closed) Base URL: https://chromium.googlesource.com/chromium/src@rls-enable
Patch Set: Elminate unnecessary #include. Created 4 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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/web/tests/VisualViewportTest.cpp
diff --git a/third_party/WebKit/Source/web/tests/VisualViewportTest.cpp b/third_party/WebKit/Source/web/tests/VisualViewportTest.cpp
index bf4f4cd7a8e304fbc1b3e88d314a9f6d99ee7a7c..10b249dbcbfc52a3db1eee5425d654fe197f2e47 100644
--- a/third_party/WebKit/Source/web/tests/VisualViewportTest.cpp
+++ b/third_party/WebKit/Source/web/tests/VisualViewportTest.cpp
@@ -188,15 +188,9 @@ private:
FrameTestHelpers::WebViewHelper m_helper;
};
-typedef void (*SettingOverrideFunction)(WebSettings*);
-
-static void DefaultSettingOverride(WebSettings *)
-{
-}
-
class ParameterizedVisualViewportTest
: public VisualViewportTest
- , public testing::WithParamInterface<SettingOverrideFunction> {
+ , public testing::WithParamInterface<FrameTestHelpers::SettingOverrideFunction> {
public:
void overrideSettings(WebSettings *settings) override
{
@@ -204,13 +198,9 @@ public:
}
};
-static void RootLayerScrollsSettingOverride(WebSettings *settings)
-{
- settings->setRootLayerScrolls(true);
-}
INSTANTIATE_TEST_CASE_P(All, ParameterizedVisualViewportTest, ::testing::Values(
- DefaultSettingOverride,
- RootLayerScrollsSettingOverride));
+ FrameTestHelpers::DefaultSettingOverride,
+ FrameTestHelpers::RootLayerScrollsSettingOverride));
// Test that resizing the VisualViewport works as expected and that resizing the
// WebView resizes the VisualViewport.
« no previous file with comments | « third_party/WebKit/Source/web/tests/FrameTestHelpers.cpp ('k') | third_party/WebKit/Source/web/tests/WebFrameTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698