| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 "shell/application_manager/application_manager.h" | 5 #include "shell/application_manager/application_manager.h" |
| 6 | 6 |
| 7 #include <utility> | 7 #include <utility> |
| 8 | 8 |
| 9 #include "base/at_exit.h" | 9 #include "base/at_exit.h" |
| 10 #include "base/bind.h" | 10 #include "base/bind.h" |
| (...skipping 771 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 782 EXPECT_EQ(1, scheme_loader->num_loads()); | 782 EXPECT_EQ(1, scheme_loader->num_loads()); |
| 783 } | 783 } |
| 784 | 784 |
| 785 TEST_F(ApplicationManagerTest, TestEndApplicationClosure) { | 785 TEST_F(ApplicationManagerTest, TestEndApplicationClosure) { |
| 786 ClosingApplicationLoader* loader = new ClosingApplicationLoader(); | 786 ClosingApplicationLoader* loader = new ClosingApplicationLoader(); |
| 787 application_manager_->SetLoaderForScheme( | 787 application_manager_->SetLoaderForScheme( |
| 788 scoped_ptr<ApplicationLoader>(loader), "test"); | 788 scoped_ptr<ApplicationLoader>(loader), "test"); |
| 789 | 789 |
| 790 bool called = false; | 790 bool called = false; |
| 791 application_manager_->ConnectToApplication( | 791 application_manager_->ConnectToApplication( |
| 792 GURL("test:test"), GURL(), nullptr, nullptr, | 792 GURL("test:test"), GURL(), nullptr, |
| 793 base::Bind(&QuitClosure, base::Unretained(&called))); | 793 base::Bind(&QuitClosure, base::Unretained(&called))); |
| 794 loop_.Run(); | 794 loop_.Run(); |
| 795 EXPECT_TRUE(called); | 795 EXPECT_TRUE(called); |
| 796 } | 796 } |
| 797 | 797 |
| 798 } // namespace | 798 } // namespace |
| 799 } // namespace shell | 799 } // namespace shell |
| OLD | NEW |