Index: content/public/test/browser_test_base.h |
diff --git a/content/public/test/browser_test_base.h b/content/public/test/browser_test_base.h |
index 26f7c0700205871ac5cc29acbdf011ab945ad854..521ba76955c4829f0f17834a14c7222de6134e52 100644 |
--- a/content/public/test/browser_test_base.h |
+++ b/content/public/test/browser_test_base.h |
@@ -109,6 +109,9 @@ class BrowserTestBase : public testing::Test { |
// returns. |
void PostTaskToInProcessRendererAndWait(const base::Closure& task); |
+ // Call this in SetUp() to use real GL contexts in Compositor for the test. |
+ void DoNotUseTestContexts() { allow_test_contexts_ = false; } |
+ |
private: |
void ProxyRunTestOnMainThreadLoop(); |
@@ -118,6 +121,10 @@ class BrowserTestBase : public testing::Test { |
// Embedded test server, cheap to create, started on demand. |
scoped_ptr<net::test_server::EmbeddedTestServer> embedded_test_server_; |
+ // When false, the ui::Compositor will be forced to use real GL contexts for |
+ // the test, so that it produces real pixel output. |
+ bool allow_test_contexts_; |
+ |
#if defined(OS_POSIX) |
bool handle_sigterm_; |
#endif |