| OLD | NEW |
| 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 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/file_util.h" | 5 #include "base/file_util.h" |
| 6 #include "base/path_service.h" | 6 #include "base/path_service.h" |
| 7 #include "base/platform_thread.h" | 7 #include "base/platform_thread.h" |
| 8 #include "base/string_util.h" | 8 #include "base/string_util.h" |
| 9 #include "base/test/test_file_util.h" | 9 #include "base/test/test_file_util.h" |
| 10 #include "chrome/app/chrome_dll_resource.h" | 10 #include "chrome/app/chrome_dll_resource.h" |
| (...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 77 FilePath(kTestDir).Append(file_name)); | 77 FilePath(kTestDir).Append(file_name)); |
| 78 scoped_refptr<TabProxy> tab(GetActiveTab()); | 78 scoped_refptr<TabProxy> tab(GetActiveTab()); |
| 79 ASSERT_TRUE(tab.get()); | 79 ASSERT_TRUE(tab.get()); |
| 80 ASSERT_TRUE(tab->NavigateToURL(url)); | 80 ASSERT_TRUE(tab->NavigateToURL(url)); |
| 81 WaitUntilTabCount(1); | 81 WaitUntilTabCount(1); |
| 82 | 82 |
| 83 scoped_refptr<BrowserProxy> browser(automation()->GetBrowserWindow(0)); | 83 scoped_refptr<BrowserProxy> browser(automation()->GetBrowserWindow(0)); |
| 84 ASSERT_TRUE(browser.get()); | 84 ASSERT_TRUE(browser.get()); |
| 85 automation()->SavePackageShouldPromptUser(false); | 85 automation()->SavePackageShouldPromptUser(false); |
| 86 EXPECT_TRUE(browser->RunCommandAsync(IDC_SAVE_PAGE)); | 86 EXPECT_TRUE(browser->RunCommandAsync(IDC_SAVE_PAGE)); |
| 87 EXPECT_TRUE(WaitForDownloadShelfVisible(browser.get())); | 87 EXPECT_TRUE(browser->WaitForDownloadShelfVisibilityChange(true)); |
| 88 automation()->SavePackageShouldPromptUser(true); | 88 automation()->SavePackageShouldPromptUser(true); |
| 89 | 89 |
| 90 CheckFile(full_file_name, file_name); | 90 CheckFile(full_file_name, file_name); |
| 91 EXPECT_TRUE(file_util::DieFileDie(full_file_name, false)); | 91 EXPECT_TRUE(file_util::DieFileDie(full_file_name, false)); |
| 92 EXPECT_TRUE(file_util::DieFileDie(dir, true)); | 92 EXPECT_TRUE(file_util::DieFileDie(dir, true)); |
| 93 } | 93 } |
| 94 #endif | 94 #endif |
| OLD | NEW |