OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 "base/compiler_specific.h" | 5 #include "base/compiler_specific.h" |
6 #include "base/memory/scoped_ptr.h" | 6 #include "base/memory/scoped_ptr.h" |
7 #include "base/message_loop.h" | 7 #include "base/message_loop.h" |
8 #include "chrome/test/base/testing_profile.h" | 8 #include "chrome/test/base/testing_profile.h" |
9 #include "chrome/test/testing_browser_process.h" | 9 #include "chrome/test/base/testing_browser_process.h" |
10 #include "content/browser/tab_contents/tab_contents.h" | 10 #include "content/browser/tab_contents/tab_contents.h" |
11 #include "content/browser/tab_contents/tab_contents_delegate.h" | 11 #include "content/browser/tab_contents/tab_contents_delegate.h" |
12 #include "testing/gtest/include/gtest/gtest.h" | 12 #include "testing/gtest/include/gtest/gtest.h" |
13 | 13 |
14 namespace { | 14 namespace { |
15 | 15 |
16 class MockTabContentsDelegate : public TabContentsDelegate { | 16 class MockTabContentsDelegate : public TabContentsDelegate { |
17 public: | 17 public: |
18 virtual ~MockTabContentsDelegate() {} | 18 virtual ~MockTabContentsDelegate() {} |
19 | 19 |
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
101 EXPECT_TRUE(contents_a->delegate() == NULL); | 101 EXPECT_TRUE(contents_a->delegate() == NULL); |
102 EXPECT_TRUE(contents_b->delegate() == NULL); | 102 EXPECT_TRUE(contents_b->delegate() == NULL); |
103 | 103 |
104 // Destroy the tab contents and run the message loop to prevent leaks. | 104 // Destroy the tab contents and run the message loop to prevent leaks. |
105 contents_a.reset(NULL); | 105 contents_a.reset(NULL); |
106 contents_b.reset(NULL); | 106 contents_b.reset(NULL); |
107 loop.RunAllPending(); | 107 loop.RunAllPending(); |
108 } | 108 } |
109 | 109 |
110 } // namespace | 110 } // namespace |
OLD | NEW |