Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(490)

Side by Side Diff: printing/backend/cups_helper_unittest.cc

Issue 345453005: Fixed C++ type conversion. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Wed 06/18/2014 10:25:34.94 Created 6 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « printing/backend/cups_helper.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 "printing/backend/cups_helper.h" 5 #include "printing/backend/cups_helper.h"
6 #include "printing/backend/print_backend.h" 6 #include "printing/backend/print_backend.h"
7 #include "testing/gtest/include/gtest/gtest.h" 7 #include "testing/gtest/include/gtest/gtest.h"
8 8
9 TEST(PrintBackendCupsHelperTest, TestPpdParsingNoColorDuplexLongEdge) { 9 TEST(PrintBackendCupsHelperTest, TestPpdParsingNoColorDuplexLongEdge) {
10 std::string test_ppd_data; 10 std::string test_ppd_data;
(...skipping 180 matching lines...) Expand 10 before | Expand all | Expand 10 after
191 "*DefaultPaperDimension: Letter\n" 191 "*DefaultPaperDimension: Letter\n"
192 "*PaperDimension Letter/US Letter: \"612 792\"\n" 192 "*PaperDimension Letter/US Letter: \"612 792\"\n"
193 "*PaperDimension Legal/US Legal: \"612 1008\"\n\n" 193 "*PaperDimension Legal/US Legal: \"612 1008\"\n\n"
194 "*CloseUI: *PageSize\n\n"); 194 "*CloseUI: *PageSize\n\n");
195 195
196 printing::PrinterSemanticCapsAndDefaults caps; 196 printing::PrinterSemanticCapsAndDefaults caps;
197 EXPECT_TRUE(printing::ParsePpdCapabilities("test", test_ppd_data, &caps)); 197 EXPECT_TRUE(printing::ParsePpdCapabilities("test", test_ppd_data, &caps));
198 ASSERT_EQ(2UL, caps.papers.size()); 198 ASSERT_EQ(2UL, caps.papers.size());
199 EXPECT_EQ("Letter", caps.papers[0].vendor_id); 199 EXPECT_EQ("Letter", caps.papers[0].vendor_id);
200 EXPECT_EQ("US Letter", caps.papers[0].display_name); 200 EXPECT_EQ("US Letter", caps.papers[0].display_name);
201 EXPECT_EQ(214200, caps.papers[0].size_um.width()); 201 EXPECT_EQ(215900, caps.papers[0].size_um.width());
202 EXPECT_EQ(277200, caps.papers[0].size_um.height()); 202 EXPECT_EQ(279400, caps.papers[0].size_um.height());
203 EXPECT_EQ("Legal", caps.papers[1].vendor_id); 203 EXPECT_EQ("Legal", caps.papers[1].vendor_id);
204 EXPECT_EQ("US Legal", caps.papers[1].display_name); 204 EXPECT_EQ("US Legal", caps.papers[1].display_name);
205 EXPECT_EQ(214200, caps.papers[1].size_um.width()); 205 EXPECT_EQ(215900, caps.papers[1].size_um.width());
206 EXPECT_EQ(352800, caps.papers[1].size_um.height()); 206 EXPECT_EQ(355600, caps.papers[1].size_um.height());
207 } 207 }
OLDNEW
« no previous file with comments | « printing/backend/cups_helper.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698