Index: chrome_frame/test/chrome_frame_test_utils.h |
diff --git a/chrome_frame/test/chrome_frame_test_utils.h b/chrome_frame/test/chrome_frame_test_utils.h |
index bb3480dff3702f2d291b9a536268a490d5f822af..5d2e44c87d672b7785445e447ada59d40535c859 100644 |
--- a/chrome_frame/test/chrome_frame_test_utils.h |
+++ b/chrome_frame/test/chrome_frame_test_utils.h |
@@ -25,7 +25,6 @@ |
#include "base/time.h" |
#include "base/win/registry.h" |
#include "base/win/scoped_comptr.h" |
-#include "chrome/test/base/ui_test_utils.h" |
#include "chrome_frame/chrome_tab.h" |
#include "chrome_frame/test/simulate_input.h" |
#include "chrome_frame/test_utils.h" |
@@ -58,6 +57,9 @@ base::ProcessHandle LaunchChrome(const std::wstring& url, |
// not perform this initialization itself. |
int CloseAllIEWindows(); |
+// Saves a screen snapshot to the desktop and logs its location. |
+bool TakeSnapshotAndLog(); |
+ |
extern const wchar_t kIEImageName[]; |
extern const wchar_t kIEBrokerImageName[]; |
extern const char kChromeImageName[]; |
@@ -246,21 +248,7 @@ class TimedMsgLoop { |
private: |
static void SnapshotAndQuit() { |
- base::FilePath snapshot; |
- if (ui_test_utils::SaveScreenSnapshotToDesktop(&snapshot)) { |
- testing::UnitTest* unit_test = testing::UnitTest::GetInstance(); |
- const testing::TestInfo* test_info = unit_test->current_test_info(); |
- std::string name; |
- if (test_info != NULL) { |
- name.append(test_info->test_case_name()) |
- .append(1, '.') |
- .append(test_info->name()); |
- } else { |
- name = "unknown test"; |
- } |
- LOG(ERROR) << name << " timed out. Screen snapshot saved to " |
- << snapshot.value(); |
- } |
+ TakeSnapshotAndLog(); |
MessageLoop::current()->Quit(); |
} |