Index: chrome/browser/ui/cocoa/constrained_window/cw_button_unittest.mm |
diff --git a/chrome/browser/ui/cocoa/constrained_window/cw_button_unittest.mm b/chrome/browser/ui/cocoa/constrained_window/cw_button_unittest.mm |
deleted file mode 100644 |
index 37c87f21a19999a296a352b52ababa9f58f82a7f..0000000000000000000000000000000000000000 |
--- a/chrome/browser/ui/cocoa/constrained_window/cw_button_unittest.mm |
+++ /dev/null |
@@ -1,60 +0,0 @@ |
-// Copyright (c) 2012 The Chromium Authors. All rights reserved. |
-// Use of this source code is governed by a BSD-style license that can be |
-// found in the LICENSE file. |
- |
-#import "base/memory/scoped_nsobject.h" |
-#import "chrome/browser/ui/cocoa/constrained_window/cw_button.h" |
-#import "chrome/browser/ui/cocoa/cocoa_test_helper.h" |
-#include "testing/gtest/include/gtest/gtest.h" |
-#include "testing/platform_test.h" |
- |
-class CWButtonTest : public CocoaTest { |
- public: |
- CWButtonTest() { |
- NSRect frame = NSMakeRect(0, 0, 50, 30); |
- button_.reset([[CWButton alloc] initWithFrame:frame]); |
- [button_ setTitle:@"Abcdefg"]; |
- [button_ sizeToFit]; |
- [[test_window() contentView] addSubview:button_]; |
- } |
- |
- protected: |
- scoped_nsobject<CWButton> button_; |
-}; |
- |
-TEST_VIEW(CWButtonTest, button_) |
- |
-// Test hover, mostly to ensure nothing leaks or crashes. |
-TEST_F(CWButtonTest, DisplayWithHover) { |
- [[button_ cell] setIsMouseInside:NO]; |
- [button_ display]; |
- [[button_ cell] setIsMouseInside:YES]; |
- [button_ display]; |
-} |
- |
-// Test disabled, mostly to ensure nothing leaks or crashes. |
-TEST_F(CWButtonTest, DisplayWithDisable) { |
- [button_ setEnabled:YES]; |
- [button_ display]; |
- [button_ setEnabled:NO]; |
- [button_ display]; |
-} |
- |
-// Test pushed, mostly to ensure nothing leaks or crashes. |
-TEST_F(CWButtonTest, DisplayWithPushed) { |
- [[button_ cell] setHighlighted:NO]; |
- [button_ display]; |
- [[button_ cell] setHighlighted:YES]; |
- [button_ display]; |
-} |
- |
-// Tracking rects |
-TEST_F(CWButtonTest, TrackingRects) { |
- CWButtonCell* cell = [button_ cell]; |
- EXPECT_FALSE([cell isMouseInside]); |
- |
- [button_ mouseEntered:nil]; |
- EXPECT_TRUE([cell isMouseInside]); |
- [button_ mouseExited:nil]; |
- EXPECT_FALSE([cell isMouseInside]); |
-} |