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

Unified Diff: chromeos/binder/writable_transaction_data_unittest.cc

Issue 1540803002: Switch to standard integer types in chromeos/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: more includes Created 5 years 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chromeos/binder/writable_transaction_data.cc ('k') | chromeos/cert_loader.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chromeos/binder/writable_transaction_data_unittest.cc
diff --git a/chromeos/binder/writable_transaction_data_unittest.cc b/chromeos/binder/writable_transaction_data_unittest.cc
index a77a9477a0bcb39090ff1baa279dead237c3a7da..07d1d3157ee89a8fcfd6089b91dbba87f7a8e299 100644
--- a/chromeos/binder/writable_transaction_data_unittest.cc
+++ b/chromeos/binder/writable_transaction_data_unittest.cc
@@ -2,6 +2,9 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include <stddef.h>
+#include <stdint.h>
+
#include "chromeos/binder/buffer_reader.h"
#include "chromeos/binder/writable_transaction_data.h"
#include "testing/gtest/include/gtest/gtest.h"
@@ -25,52 +28,52 @@ TEST(BinderWritableTransactionDataTest, WriteData) {
}
TEST(BinderWritableTransactionDataTest, WriteInt32) {
- const int32 kValue = -1234;
+ const int32_t kValue = -1234;
WritableTransactionData data;
data.WriteInt32(kValue);
EXPECT_EQ(sizeof(kValue), data.GetDataSize());
BufferReader reader(reinterpret_cast<const char*>(data.GetData()),
data.GetDataSize());
- int32 result = 0;
+ int32_t result = 0;
EXPECT_TRUE(reader.Read(&result, sizeof(result)));
EXPECT_EQ(kValue, result);
EXPECT_FALSE(reader.HasMoreData());
}
TEST(BinderWritableTransactionDataTest, WriteUint32) {
- const uint32 kValue = 1234;
+ const uint32_t kValue = 1234;
WritableTransactionData data;
data.WriteUint32(kValue);
EXPECT_EQ(sizeof(kValue), data.GetDataSize());
BufferReader reader(reinterpret_cast<const char*>(data.GetData()),
data.GetDataSize());
- uint32 result = 0;
+ uint32_t result = 0;
EXPECT_TRUE(reader.Read(&result, sizeof(result)));
EXPECT_EQ(kValue, result);
EXPECT_FALSE(reader.HasMoreData());
}
TEST(BinderWritableTransactionDataTest, WriteInt64) {
- const int64 kValue = -1234;
+ const int64_t kValue = -1234;
WritableTransactionData data;
data.WriteInt64(kValue);
EXPECT_EQ(sizeof(kValue), data.GetDataSize());
BufferReader reader(reinterpret_cast<const char*>(data.GetData()),
data.GetDataSize());
- int64 result = 0;
+ int64_t result = 0;
EXPECT_TRUE(reader.Read(&result, sizeof(result)));
EXPECT_EQ(kValue, result);
EXPECT_FALSE(reader.HasMoreData());
}
TEST(BinderWritableTransactionDataTest, WriteUint64) {
- const uint64 kValue = 1234;
+ const uint64_t kValue = 1234;
WritableTransactionData data;
data.WriteUint64(kValue);
EXPECT_EQ(sizeof(kValue), data.GetDataSize());
BufferReader reader(reinterpret_cast<const char*>(data.GetData()),
data.GetDataSize());
- uint64 result = 0;
+ uint64_t result = 0;
EXPECT_TRUE(reader.Read(&result, sizeof(result)));
EXPECT_EQ(kValue, result);
EXPECT_FALSE(reader.HasMoreData());
« no previous file with comments | « chromeos/binder/writable_transaction_data.cc ('k') | chromeos/cert_loader.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698