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

Side by Side Diff: mojo/public/tests/system_core_perftest.cc

Issue 68203005: Mojo: Make tests under mojo/public use our own run_all_unittests.cc. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 1 month 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 | Annotate | Revision Log
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 "mojo/public/system/core.h" 5 #include "mojo/public/system/core.h"
6 6
7 #include "base/basictypes.h" 7 #include "base/basictypes.h"
8 #include "base/bind.h" 8 #include "base/bind.h"
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "mojo/public/tests/test_support.h" 10 #include "mojo/public/tests/test_support.h"
11 #include "testing/gtest/include/gtest/gtest.h"
11 12
12 namespace mojo { 13 namespace mojo {
13 namespace { 14 namespace {
14 15
15 class SystemPerftest : public test::TestBase { 16 class SystemPerftest : public testing::Test {
16 public: 17 public:
17 SystemPerftest() {} 18 SystemPerftest() {}
18 virtual ~SystemPerftest() {} 19 virtual ~SystemPerftest() {}
19 20
20 void NoOp() { 21 void NoOp() {
21 } 22 }
22 23
23 void MessagePipe_CreateAndClose() { 24 void MessagePipe_CreateAndClose() {
24 MojoResult result; 25 MojoResult result;
25 result = CreateMessagePipe(&h_0_, &h_1_); 26 result = CreateMessagePipe(&h_0_, &h_1_);
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after
109 test::IterateAndReportPerf( 110 test::IterateAndReportPerf(
110 "MessagePipe_EmptyRead", 111 "MessagePipe_EmptyRead",
111 base::Bind(&SystemPerftest::MessagePipe_EmptyRead, 112 base::Bind(&SystemPerftest::MessagePipe_EmptyRead,
112 base::Unretained(this))); 113 base::Unretained(this)));
113 CHECK_EQ(Close(h_0_), MOJO_RESULT_OK); 114 CHECK_EQ(Close(h_0_), MOJO_RESULT_OK);
114 CHECK_EQ(Close(h_1_), MOJO_RESULT_OK); 115 CHECK_EQ(Close(h_1_), MOJO_RESULT_OK);
115 } 116 }
116 117
117 } // namespace 118 } // namespace
118 } // namespace mojo 119 } // namespace mojo
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698