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

Side by Side Diff: base/trace_event/trace_event_argument_unittest.cc

Issue 885443002: Roll Chrome into Mojo. (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Rebase to ToT mojo Created 5 years, 10 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 | « base/trace_event/trace_event_argument.cc ('k') | base/trace_event/trace_event_impl.h » ('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) 2014 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2014 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/debug/trace_event_argument.h" 5 #include "base/trace_event/trace_event_argument.h"
6 #include "testing/gtest/include/gtest/gtest.h" 6 #include "testing/gtest/include/gtest/gtest.h"
7 7
8 namespace base { 8 namespace base {
9 namespace debug { 9 namespace debug {
10 10
11 TEST(TraceEventArgumentTest, FlatDictionary) { 11 TEST(TraceEventArgumentTest, FlatDictionary) {
12 scoped_refptr<TracedValue> value = new TracedValue(); 12 scoped_refptr<TracedValue> value = new TracedValue();
13 value->SetInteger("int", 2014); 13 value->SetInteger("int", 2014);
14 value->SetDouble("double", 0.0); 14 value->SetDouble("double", 0.0);
15 value->SetBoolean("bool", true); 15 value->SetBoolean("bool", true);
(...skipping 28 matching lines...) Expand all
44 value->AppendAsTraceFormat(&json); 44 value->AppendAsTraceFormat(&json);
45 EXPECT_EQ( 45 EXPECT_EQ(
46 "{\"a1\":[1,true,{\"i2\":3}],\"b0\":true,\"d0\":0.0,\"dict1\":{\"dict2\":" 46 "{\"a1\":[1,true,{\"i2\":3}],\"b0\":true,\"d0\":0.0,\"dict1\":{\"dict2\":"
47 "{\"b2\":false},\"i1\":2014,\"s1\":\"foo\"},\"i0\":2014,\"s0\":" 47 "{\"b2\":false},\"i1\":2014,\"s1\":\"foo\"},\"i0\":2014,\"s0\":"
48 "\"foo\"}", 48 "\"foo\"}",
49 json); 49 json);
50 } 50 }
51 51
52 } // namespace debug 52 } // namespace debug
53 } // namespace base 53 } // namespace base
OLDNEW
« no previous file with comments | « base/trace_event/trace_event_argument.cc ('k') | base/trace_event/trace_event_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698