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

Side by Side Diff: third_party/WebKit/Source/bindings/core/v8/ActivityLoggerTest.cpp

Issue 2967013002: Be explicit about namespace testing to not mix it with blink::testing (Closed)
Patch Set: Dropped mojo parts that need another review. Created 3 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
« no previous file with comments | « no previous file | third_party/WebKit/Source/modules/accessibility/AXObjectTest.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "bindings/core/v8/ScriptController.h" 5 #include "bindings/core/v8/ScriptController.h"
6 #include "bindings/core/v8/ScriptSourceCode.h" 6 #include "bindings/core/v8/ScriptSourceCode.h"
7 #include "bindings/core/v8/V8BindingForCore.h" 7 #include "bindings/core/v8/V8BindingForCore.h"
8 #include "bindings/core/v8/V8DOMActivityLogger.h" 8 #include "bindings/core/v8/V8DOMActivityLogger.h"
9 #include "core/frame/FrameTestHelpers.h" 9 #include "core/frame/FrameTestHelpers.h"
10 #include "core/frame/WebLocalFrameBase.h" 10 #include "core/frame/WebLocalFrameBase.h"
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
63 EXPECT_STREQ(expected[i].Utf8().data(), 63 EXPECT_STREQ(expected[i].Utf8().data(),
64 logged_activities_[i].Utf8().data()); 64 logged_activities_[i].Utf8().data());
65 } 65 }
66 return logged_activities_ == expected; 66 return logged_activities_ == expected;
67 } 67 }
68 68
69 private: 69 private:
70 Vector<String> logged_activities_; 70 Vector<String> logged_activities_;
71 }; 71 };
72 72
73 class ActivityLoggerTest : public testing::Test { 73 class ActivityLoggerTest : public ::testing::Test {
74 protected: 74 protected:
75 ActivityLoggerTest() { 75 ActivityLoggerTest() {
76 activity_logger_ = new TestActivityLogger(); 76 activity_logger_ = new TestActivityLogger();
77 V8DOMActivityLogger::SetActivityLogger(kIsolatedWorldId, String(), 77 V8DOMActivityLogger::SetActivityLogger(kIsolatedWorldId, String(),
78 WTF::WrapUnique(activity_logger_)); 78 WTF::WrapUnique(activity_logger_));
79 web_view_helper_.Initialize(); 79 web_view_helper_.Initialize();
80 script_controller_ = &web_view_helper_.WebView() 80 script_controller_ = &web_view_helper_.WebView()
81 ->MainFrameImpl() 81 ->MainFrameImpl()
82 ->GetFrame() 82 ->GetFrame()
83 ->GetScriptController(); 83 ->GetScriptController();
(...skipping 504 matching lines...) Expand 10 before | Expand all | Expand 10 after
588 "blinkRequestResource | Script | data:text/html;charset=utf-8,D\n" 588 "blinkRequestResource | Script | data:text/html;charset=utf-8,D\n"
589 "blinkRequestResource | XMLHttpRequest | data:text/html;charset=utf-8,E\n" 589 "blinkRequestResource | XMLHttpRequest | data:text/html;charset=utf-8,E\n"
590 "blinkRequestResource | Image | data:text/html;charset=utf-8,B\n"; 590 "blinkRequestResource | Image | data:text/html;charset=utf-8,B\n";
591 ExecuteScriptInMainWorld(code); 591 ExecuteScriptInMainWorld(code);
592 ASSERT_TRUE(VerifyActivities("")); 592 ASSERT_TRUE(VerifyActivities(""));
593 ExecuteScriptInIsolatedWorld(code); 593 ExecuteScriptInIsolatedWorld(code);
594 ASSERT_TRUE(VerifyActivities(expected_activities)); 594 ASSERT_TRUE(VerifyActivities(expected_activities));
595 } 595 }
596 596
597 } // namespace blink 597 } // namespace blink
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/modules/accessibility/AXObjectTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698