| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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/sys_string_conversions.h" | 5 #include "base/sys_string_conversions.h" |
| 6 #include "chrome/browser/cocoa/cocoa_test_helper.h" | 6 #include "chrome/browser/cocoa/cocoa_test_helper.h" |
| 7 #include "chrome/browser/cocoa/cookie_details.h" | 7 #include "chrome/browser/cocoa/cookie_details.h" |
| 8 #include "chrome/browser/cocoa/cookie_details_view_controller.h" | 8 #include "chrome/browser/cocoa/cookie_details_view_controller.h" |
| 9 #include "chrome/browser/cookie_modal_dialog.h" | |
| 10 | 9 |
| 11 namespace { | 10 namespace { |
| 12 | 11 |
| 13 class CookieDetailsViewControllerTest : public CocoaTest { | 12 class CookieDetailsViewControllerTest : public CocoaTest { |
| 14 }; | 13 }; |
| 15 | 14 |
| 16 static CocoaCookieDetails* CreateTestCookieDetails(BOOL canEditExpiration) { | 15 static CocoaCookieDetails* CreateTestCookieDetails(BOOL canEditExpiration) { |
| 17 GURL url("http://chromium.org"); | 16 GURL url("http://chromium.org"); |
| 18 std::string cookieLine( | 17 std::string cookieLine( |
| 19 "PHPSESSID=0123456789abcdef0123456789abcdef; path=/"); | 18 "PHPSESSID=0123456789abcdef0123456789abcdef; path=/"); |
| (...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 80 | 79 |
| 81 EXPECT_FALSE([detailsViewController.get() hasExpiration]); | 80 EXPECT_FALSE([detailsViewController.get() hasExpiration]); |
| 82 [detailsViewController.get() setCookieHasExplicitExpiration:adapter.get()]; | 81 [detailsViewController.get() setCookieHasExplicitExpiration:adapter.get()]; |
| 83 EXPECT_TRUE([detailsViewController.get() hasExpiration]); | 82 EXPECT_TRUE([detailsViewController.get() hasExpiration]); |
| 84 [detailsViewController.get() | 83 [detailsViewController.get() |
| 85 setCookieDoesntHaveExplicitExpiration:adapter.get()]; | 84 setCookieDoesntHaveExplicitExpiration:adapter.get()]; |
| 86 EXPECT_FALSE([detailsViewController.get() hasExpiration]); | 85 EXPECT_FALSE([detailsViewController.get() hasExpiration]); |
| 87 } | 86 } |
| 88 | 87 |
| 89 } // namespace | 88 } // namespace |
| OLD | NEW |