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

Unified Diff: chrome/browser/ui/cocoa/infobars/translate_infobar_unittest.mm

Issue 10868072: Make TabContents ctor private; poke hole for existing callers. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: all green Created 8 years, 4 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: chrome/browser/ui/cocoa/infobars/translate_infobar_unittest.mm
diff --git a/chrome/browser/ui/cocoa/infobars/translate_infobar_unittest.mm b/chrome/browser/ui/cocoa/infobars/translate_infobar_unittest.mm
index fafdca57fdd90a8f13b3540b6d52a595ce619f34..d0b3205e8608d23e376a61e29afcc6bc62603982 100644
--- a/chrome/browser/ui/cocoa/infobars/translate_infobar_unittest.mm
+++ b/chrome/browser/ui/cocoa/infobars/translate_infobar_unittest.mm
@@ -23,6 +23,14 @@
using content::WebContents;
+// TODO(avi): Kill this when TabContents goes away.
+class TranslationInfoBarTestContentsCreator {
+ public:
+ static TabContents* CreateTabContents(content::WebContents* contents) {
+ return TabContents::Factory::CreateTabContents(contents);
+ }
+};
+
namespace {
// All states the translate toolbar can assume.
@@ -76,8 +84,9 @@ class TranslationInfoBarTest : public CocoaProfileTest {
// the test.
virtual void SetUp() {
CocoaProfileTest::SetUp();
- tab_contents_.reset(new TabContents(WebContents::Create(
- profile(), NULL, MSG_ROUTING_NONE, NULL)));
+ tab_contents_.reset(
+ TranslationInfoBarTestContentsCreator::CreateTabContents(
+ WebContents::Create(profile(), NULL, MSG_ROUTING_NONE, NULL)));
CreateInfoBar();
}

Powered by Google App Engine
This is Rietveld 408576698