Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 #ifndef CONTENT_PUBLIC_TEST_BROWSER_TEST_UTILS_H_ | 5 #ifndef CONTENT_PUBLIC_TEST_BROWSER_TEST_UTILS_H_ |
| 6 #define CONTENT_PUBLIC_TEST_BROWSER_TEST_UTILS_H_ | 6 #define CONTENT_PUBLIC_TEST_BROWSER_TEST_UTILS_H_ |
| 7 | 7 |
| 8 #include <queue> | 8 #include <queue> |
| 9 #include <string> | 9 #include <string> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 832 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 843 bool user_gesture, | 843 bool user_gesture, |
| 844 bool last_unlocked_by_target, | 844 bool last_unlocked_by_target, |
| 845 bool privileged); | 845 bool privileged); |
| 846 | 846 |
| 847 private: | 847 private: |
| 848 PwnMessageHelper(); // Not instantiable. | 848 PwnMessageHelper(); // Not instantiable. |
| 849 | 849 |
| 850 DISALLOW_COPY_AND_ASSIGN(PwnMessageHelper); | 850 DISALLOW_COPY_AND_ASSIGN(PwnMessageHelper); |
| 851 }; | 851 }; |
| 852 | 852 |
| 853 #if defined(USE_AURA) | |
| 854 // Wraps an OverscrollController so we can inspect the scroll events that it | |
| 855 // receives. | |
| 856 // TODO(mcnee): Tests needing this are BrowserPlugin specific | |
| 857 // (crbug.com/533069). | |
|
Charlie Reis
2017/05/30 22:35:17
I don't understand this TODO. Can you rephrase it
Kevin McNee
2017/05/31 18:07:35
Done.
| |
| 858 class OverscrollControllerSpy { | |
|
Charlie Reis
2017/05/30 22:35:17
Is spy a design pattern? I don't many instances o
Kevin McNee
2017/05/31 18:07:35
It's essentially a partial mock. We're inspecting
| |
| 859 public: | |
| 860 // Creates a spy and installs it on the given RenderWidgetHostViewAura. | |
| 861 // The returned spy is owned by the RWHVA. | |
| 862 static OverscrollControllerSpy* Create(RenderWidgetHostView* rwhv); | |
| 863 | |
| 864 virtual ~OverscrollControllerSpy() {} | |
| 865 | |
| 866 virtual void WaitForScrollStateContentScrolling() = 0; | |
|
Charlie Reis
2017/05/30 22:35:17
Needs a comment.
Kevin McNee
2017/05/31 18:07:35
Done.
| |
| 867 }; | |
| 868 #endif // defined(USE_AURA) | |
| 869 | |
| 853 } // namespace content | 870 } // namespace content |
| 854 | 871 |
| 855 #endif // CONTENT_PUBLIC_TEST_BROWSER_TEST_UTILS_H_ | 872 #endif // CONTENT_PUBLIC_TEST_BROWSER_TEST_UTILS_H_ |
| OLD | NEW |