| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 "components/tracing/test/example_proto/test_messages.pbzero.h" | 5 #include "components/tracing/test/example_proto/test_messages.pbzero.h" |
| 6 #include "testing/gtest/include/gtest/gtest.h" | 6 #include "testing/gtest/include/gtest/gtest.h" |
| 7 | 7 |
| 8 namespace tracing { | 8 namespace tracing { |
| 9 namespace proto { | 9 namespace proto { |
| 10 | 10 |
| 11 using foo::bar::CamelCaseFields; |
| 12 |
| 11 TEST(ProtoZeroTest, Simple) { | 13 TEST(ProtoZeroTest, Simple) { |
| 12 // TODO(kraynov) Put tests in the next CL (crbug.com/608721). | 14 // TODO(kraynov) Put tests in the next CL (crbug.com/608721). |
| 13 } | 15 } |
| 14 | 16 |
| 17 TEST(ProtoZeroTest, FieldNumbers) { |
| 18 // Tests camel case conversion as well. |
| 19 EXPECT_EQ(1, CamelCaseFields::kFooBarBazFieldNumber); |
| 20 EXPECT_EQ(2, CamelCaseFields::kBarBazFieldNumber); |
| 21 EXPECT_EQ(3, CamelCaseFields::kMooMooFieldNumber); |
| 22 EXPECT_EQ(4, CamelCaseFields::kURLEncoderFieldNumber); |
| 23 EXPECT_EQ(5, CamelCaseFields::kXMapFieldNumber); |
| 24 EXPECT_EQ(6, CamelCaseFields::kUrLENcoDerFieldNumber); |
| 25 EXPECT_EQ(7, CamelCaseFields::kBigBangFieldNumber); |
| 26 EXPECT_EQ(8, CamelCaseFields::kU2FieldNumber); |
| 27 EXPECT_EQ(9, CamelCaseFields::kBangBigFieldNumber); |
| 28 } |
| 29 |
| 15 } // namespace proto | 30 } // namespace proto |
| 16 } // namespace tracing | 31 } // namespace tracing |
| OLD | NEW |