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 3 // found in the LICENSE file. 4 5 #import <Cocoa/Cocoa.h> 6 7 #import "base/memory/scoped_nsobject.h" 8 #include "chrome/browser/ui/cocoa/browser_test_helper.h" 9 #include "chrome/browser/ui/cocoa/cocoa_test_helper.h" 10 #import "chrome/browser/ui/cocoa/tab_contents/previewable_contents_controller.h" 11 #include "testing/gtest/include/gtest/gtest.h" 12 #include "testing/platform_test.h" 13 14 namespace { 15 16 class PreviewableContentsControllerTest : public CocoaTest { 17 public: 18 virtual void SetUp() { 19 CocoaTest::SetUp(); 20 controller_.reset([[PreviewableContentsController alloc] init]); 21 [[test_window() contentView] addSubview:[controller_ view]]; 22 } 23 24 scoped_nsobject<PreviewableContentsController> controller_; 25 }; 26 27 TEST_VIEW(PreviewableContentsControllerTest, [controller_ view]) 28 29 // TODO(rohitrao): Test showing and hiding the preview. This may require 30 // changing the interface to take in a TabContentsView* instead of a 31 // TabContents*. 32 33 } // namespace 34 35