OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "content/browser/renderer_host/pepper/browser_ppapi_host_test.h" | 5 #include "content/browser/renderer_host/pepper/browser_ppapi_host_test.h" |
6 #include "content/browser/renderer_host/pepper/pepper_print_settings_manager.h" | 6 #include "content/browser/renderer_host/pepper/pepper_print_settings_manager.h" |
7 #include "content/browser/renderer_host/pepper/pepper_printing_host.h" | 7 #include "content/browser/renderer_host/pepper/pepper_printing_host.h" |
8 #include "ppapi/c/pp_errors.h" | 8 #include "ppapi/c/pp_errors.h" |
9 #include "ppapi/host/host_message_context.h" | 9 #include "ppapi/host/host_message_context.h" |
10 #include "ppapi/host/ppapi_host.h" | 10 #include "ppapi/host/ppapi_host.h" |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
43 callback.Run(PepperPrintSettingsManager::Result(settings_, PP_OK)); | 43 callback.Run(PepperPrintSettingsManager::Result(settings_, PP_OK)); |
44 } | 44 } |
45 | 45 |
46 class PepperPrintingHostTest | 46 class PepperPrintingHostTest |
47 : public testing::Test, | 47 : public testing::Test, |
48 public BrowserPpapiHostTest { | 48 public BrowserPpapiHostTest { |
49 public: | 49 public: |
50 PepperPrintingHostTest() { | 50 PepperPrintingHostTest() { |
51 } | 51 } |
52 | 52 |
53 ~PepperPrintingHostTest() { | 53 virtual ~PepperPrintingHostTest() { |
54 } | 54 } |
55 | 55 |
56 DISALLOW_COPY_AND_ASSIGN(PepperPrintingHostTest); | 56 DISALLOW_COPY_AND_ASSIGN(PepperPrintingHostTest); |
57 }; | 57 }; |
58 | 58 |
59 bool PP_SizeEqual(const PP_Size& lhs, const PP_Size& rhs) { | 59 bool PP_SizeEqual(const PP_Size& lhs, const PP_Size& rhs) { |
60 return lhs.width == rhs.width && lhs.height == rhs.height; | 60 return lhs.width == rhs.width && lhs.height == rhs.height; |
61 } | 61 } |
62 | 62 |
63 bool PP_RectEqual(const PP_Rect& lhs, const PP_Rect& rhs) { | 63 bool PP_RectEqual(const PP_Rect& lhs, const PP_Rect& rhs) { |
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
119 actual_settings.paper_size)); | 119 actual_settings.paper_size)); |
120 EXPECT_EQ(expected_settings.dpi, actual_settings.dpi); | 120 EXPECT_EQ(expected_settings.dpi, actual_settings.dpi); |
121 EXPECT_EQ(expected_settings.orientation, actual_settings.orientation); | 121 EXPECT_EQ(expected_settings.orientation, actual_settings.orientation); |
122 EXPECT_EQ(expected_settings.print_scaling_option, | 122 EXPECT_EQ(expected_settings.print_scaling_option, |
123 actual_settings.print_scaling_option); | 123 actual_settings.print_scaling_option); |
124 EXPECT_EQ(expected_settings.grayscale, actual_settings.grayscale); | 124 EXPECT_EQ(expected_settings.grayscale, actual_settings.grayscale); |
125 EXPECT_EQ(expected_settings.format, actual_settings.format); | 125 EXPECT_EQ(expected_settings.format, actual_settings.format); |
126 } | 126 } |
127 | 127 |
128 } // namespace content | 128 } // namespace content |
OLD | NEW |