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

Side by Side Diff: ui/gfx/geometry/point3_unittest.cc

Issue 1543183002: Switch to standard integer types in ui/gfx/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 12 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
« no previous file with comments | « ui/gfx/geometry/point.cc ('k') | ui/gfx/geometry/point_unittest.cc » ('j') | 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 "base/basictypes.h" 5 #include <stddef.h>
6
7 #include "base/macros.h"
6 #include "testing/gtest/include/gtest/gtest.h" 8 #include "testing/gtest/include/gtest/gtest.h"
7 #include "ui/gfx/geometry/point3_f.h" 9 #include "ui/gfx/geometry/point3_f.h"
8 10
9 namespace gfx { 11 namespace gfx {
10 12
11 TEST(Point3Test, VectorArithmetic) { 13 TEST(Point3Test, VectorArithmetic) {
12 gfx::Point3F a(1.6f, 5.1f, 3.2f); 14 gfx::Point3F a(1.6f, 5.1f, 3.2f);
13 gfx::Vector3dF v1(3.1f, -3.2f, 9.3f); 15 gfx::Vector3dF v1(3.1f, -3.2f, 9.3f);
14 gfx::Vector3dF v2(-8.1f, 1.2f, 3.3f); 16 gfx::Vector3dF v2(-8.1f, 1.2f, 3.3f);
15 17
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
60 zero.Scale(6.f, 3.f, 1.5f); 62 zero.Scale(6.f, 3.f, 1.5f);
61 EXPECT_EQ(Point3F().ToString(), zero.ToString()); 63 EXPECT_EQ(Point3F().ToString(), zero.ToString());
62 64
63 Point3F point(1.f, -1.f, 2.f); 65 Point3F point(1.f, -1.f, 2.f);
64 point.Scale(2.f); 66 point.Scale(2.f);
65 point.Scale(6.f, 3.f, 1.5f); 67 point.Scale(6.f, 3.f, 1.5f);
66 EXPECT_EQ(Point3F(12.f, -6.f, 6.f).ToString(), point.ToString()); 68 EXPECT_EQ(Point3F(12.f, -6.f, 6.f).ToString(), point.ToString());
67 } 69 }
68 70
69 } // namespace gfx 71 } // namespace gfx
OLDNEW
« no previous file with comments | « ui/gfx/geometry/point.cc ('k') | ui/gfx/geometry/point_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698