Index: ios/chrome/browser/ui/page_not_available_controller_unittest.mm |
diff --git a/ios/chrome/browser/ui/page_not_available_controller_unittest.mm b/ios/chrome/browser/ui/page_not_available_controller_unittest.mm |
new file mode 100644 |
index 0000000000000000000000000000000000000000..96f70d5ebb4ba2befd4f872ff06a7ba49cdfd50c |
--- /dev/null |
+++ b/ios/chrome/browser/ui/page_not_available_controller_unittest.mm |
@@ -0,0 +1,20 @@ |
+// Copyright 2015 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. |
+ |
+#include <gtest/gtest.h> |
+#include "base/logging.h" |
+#include "base/mac/scoped_nsobject.h" |
+#import "ios/chrome/browser/ui/page_not_available_controller.h" |
+ |
+namespace { |
+ |
+TEST(PageNotAvailableControllerTest, TestInitWithURL) { |
+ GURL url = GURL("http://foo.bar.com"); |
+ base::scoped_nsobject<PageNotAvailableController> controller( |
+ [[PageNotAvailableController alloc] initWithUrl:url]); |
+ EXPECT_EQ(url, controller.get().url); |
+ EXPECT_TRUE(controller.get().view); |
+} |
+ |
+} // namespace |