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

Unified Diff: content/browser/speech/chunked_byte_buffer_unittest.cc

Issue 1549113002: Switch to standard integer types in content/browser/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase 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 | « content/browser/speech/chunked_byte_buffer.cc ('k') | content/browser/speech/endpointer/endpointer.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/speech/chunked_byte_buffer_unittest.cc
diff --git a/content/browser/speech/chunked_byte_buffer_unittest.cc b/content/browser/speech/chunked_byte_buffer_unittest.cc
index 57fdf4ca1bf222df9ddf6d9cd82e18b4eaf61555..56919757a4ee078510ac76bb333d7f95cd3ab789 100644
--- a/content/browser/speech/chunked_byte_buffer_unittest.cc
+++ b/content/browser/speech/chunked_byte_buffer_unittest.cc
@@ -2,6 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include <stdint.h>
+
#include <string>
#include <vector>
@@ -10,15 +12,15 @@
namespace content {
-typedef std::vector<uint8> ByteVector;
+typedef std::vector<uint8_t> ByteVector;
TEST(ChunkedByteBufferTest, BasicTest) {
ChunkedByteBuffer buffer;
- const uint8 kChunks[] = {
+ const uint8_t kChunks[] = {
0x00, 0x00, 0x00, 0x04, 0x01, 0x02, 0x03, 0x04, // Chunk 1: 4 bytes
- 0x00, 0x00, 0x00, 0x02, 0x05, 0x06, // Chunk 2: 2 bytes
- 0x00, 0x00, 0x00, 0x01, 0x07 // Chunk 3: 1 bytes
+ 0x00, 0x00, 0x00, 0x02, 0x05, 0x06, // Chunk 2: 2 bytes
+ 0x00, 0x00, 0x00, 0x01, 0x07 // Chunk 3: 1 bytes
};
EXPECT_EQ(0U, buffer.GetTotalLength());
@@ -44,9 +46,8 @@ TEST(ChunkedByteBufferTest, BasicTest) {
chunk = buffer.PopChunk();
EXPECT_TRUE(chunk != NULL);
EXPECT_EQ(4U, chunk->size());
- EXPECT_EQ(0, std::char_traits<uint8>::compare(kChunks + 4,
- &(*chunk)[0],
- chunk->size()));
+ EXPECT_EQ(0, std::char_traits<uint8_t>::compare(kChunks + 4, &(*chunk)[0],
+ chunk->size()));
EXPECT_EQ(6U, buffer.GetTotalLength());
EXPECT_TRUE(buffer.HasChunks());
@@ -54,9 +55,8 @@ TEST(ChunkedByteBufferTest, BasicTest) {
chunk = buffer.PopChunk();
EXPECT_TRUE(chunk != NULL);
EXPECT_EQ(2U, chunk->size());
- EXPECT_EQ(0, std::char_traits<uint8>::compare(kChunks + 12,
- &(*chunk)[0],
- chunk->size()));
+ EXPECT_EQ(0, std::char_traits<uint8_t>::compare(kChunks + 12, &(*chunk)[0],
+ chunk->size()));
EXPECT_EQ(0U, buffer.GetTotalLength());
EXPECT_FALSE(buffer.HasChunks());
« no previous file with comments | « content/browser/speech/chunked_byte_buffer.cc ('k') | content/browser/speech/endpointer/endpointer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698