OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 <string> | 5 #include <string> |
6 | 6 |
7 #include "app/app_switches.h" | 7 #include "app/app_switches.h" |
8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
10 #include "base/file_path.h" | 10 #include "base/file_path.h" |
(...skipping 16 matching lines...) Expand all Loading... |
27 #include "chrome/common/json_value_serializer.h" | 27 #include "chrome/common/json_value_serializer.h" |
28 #include "chrome/common/url_constants.h" | 28 #include "chrome/common/url_constants.h" |
29 #include "chrome/test/automation/autocomplete_edit_proxy.h" | 29 #include "chrome/test/automation/autocomplete_edit_proxy.h" |
30 #include "chrome/test/automation/automation_proxy_uitest.h" | 30 #include "chrome/test/automation/automation_proxy_uitest.h" |
31 #include "chrome/test/automation/browser_proxy.h" | 31 #include "chrome/test/automation/browser_proxy.h" |
32 #include "chrome/test/automation/proxy_launcher.h" | 32 #include "chrome/test/automation/proxy_launcher.h" |
33 #include "chrome/test/automation/tab_proxy.h" | 33 #include "chrome/test/automation/tab_proxy.h" |
34 #include "chrome/test/automation/window_proxy.h" | 34 #include "chrome/test/automation/window_proxy.h" |
35 #include "chrome/test/ui_test_utils.h" | 35 #include "chrome/test/ui_test_utils.h" |
36 #include "chrome/test/ui/ui_test.h" | 36 #include "chrome/test/ui/ui_test.h" |
37 #include "gfx/codec/png_codec.h" | |
38 #include "gfx/rect.h" | |
39 #include "net/base/net_util.h" | 37 #include "net/base/net_util.h" |
40 #include "net/test/test_server.h" | 38 #include "net/test/test_server.h" |
41 #define GMOCK_MUTANT_INCLUDE_LATE_OBJECT_BINDING | 39 #define GMOCK_MUTANT_INCLUDE_LATE_OBJECT_BINDING |
42 #include "testing/gmock_mutant.h" | 40 #include "testing/gmock_mutant.h" |
43 #include "third_party/skia/include/core/SkBitmap.h" | 41 #include "third_party/skia/include/core/SkBitmap.h" |
44 #include "ui/base/message_box_flags.h" | 42 #include "ui/base/message_box_flags.h" |
45 #include "ui/base/ui_base_switches.h" | 43 #include "ui/base/ui_base_switches.h" |
| 44 #include "ui/gfx/codec/png_codec.h" |
| 45 #include "ui/gfx/rect.h" |
46 #include "views/event.h" | 46 #include "views/event.h" |
47 | 47 |
48 using ui_test_utils::TimedMessageLoopRunner; | 48 using ui_test_utils::TimedMessageLoopRunner; |
49 using testing::CreateFunctor; | 49 using testing::CreateFunctor; |
50 using testing::StrEq; | 50 using testing::StrEq; |
51 using testing::_; | 51 using testing::_; |
52 | 52 |
53 | 53 |
54 // Replace the default automation proxy with our mock client. | 54 // Replace the default automation proxy with our mock client. |
55 class ExternalTabUITestMockLauncher : public ProxyLauncher { | 55 class ExternalTabUITestMockLauncher : public ProxyLauncher { |
(...skipping 1700 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1756 int diff_pixels_count = 0; | 1756 int diff_pixels_count = 0; |
1757 for (int x = 0; x < img_size.width(); ++x) { | 1757 for (int x = 0; x < img_size.width(); ++x) { |
1758 for (int y = 0; y < img_size.height(); ++y) { | 1758 for (int y = 0; y < img_size.height(); ++y) { |
1759 if (*snapshot_bmp.getAddr32(x, y) != *reference_bmp.getAddr32(x, y)) { | 1759 if (*snapshot_bmp.getAddr32(x, y) != *reference_bmp.getAddr32(x, y)) { |
1760 ++diff_pixels_count; | 1760 ++diff_pixels_count; |
1761 } | 1761 } |
1762 } | 1762 } |
1763 } | 1763 } |
1764 ASSERT_EQ(diff_pixels_count, 0); | 1764 ASSERT_EQ(diff_pixels_count, 0); |
1765 } | 1765 } |
OLD | NEW |