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

Side by Side Diff: base/tools_sanity_unittest.cc

Issue 1992005: Update dynamic annotations and move them to base/third_party (Closed)
Patch Set: rebased Created 10 years, 7 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/thread_unittest.cc ('k') | build/common.gypi » ('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) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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/dynamic_annotations.h"
6 #include "base/message_loop.h" 5 #include "base/message_loop.h"
6 #include "base/third_party/dynamic_annotations/dynamic_annotations.h"
7 #include "base/thread.h" 7 #include "base/thread.h"
8 #include "testing/gtest/include/gtest/gtest.h" 8 #include "testing/gtest/include/gtest/gtest.h"
9 9
10 namespace { 10 namespace {
11 11
12 // We use caps here just to ensure that the method name doesn't interfere with 12 // We use caps here just to ensure that the method name doesn't interfere with
13 // the wildcarded suppressions. 13 // the wildcarded suppressions.
14 class TOOLS_SANITY_TEST_CONCURRENT_THREAD : public PlatformThread::Delegate { 14 class TOOLS_SANITY_TEST_CONCURRENT_THREAD : public PlatformThread::Delegate {
15 public: 15 public:
16 explicit TOOLS_SANITY_TEST_CONCURRENT_THREAD(bool *value) : value_(value) {} 16 explicit TOOLS_SANITY_TEST_CONCURRENT_THREAD(bool *value) : value_(value) {}
(...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after
111 new TOOLS_SANITY_TEST_CONCURRENT_THREAD(&shared); 111 new TOOLS_SANITY_TEST_CONCURRENT_THREAD(&shared);
112 112
113 PlatformThread::Create(0, thread1, &a); 113 PlatformThread::Create(0, thread1, &a);
114 PlatformThread::Create(0, thread2, &b); 114 PlatformThread::Create(0, thread2, &b);
115 PlatformThread::Join(a); 115 PlatformThread::Join(a);
116 PlatformThread::Join(b); 116 PlatformThread::Join(b);
117 EXPECT_TRUE(shared); 117 EXPECT_TRUE(shared);
118 delete thread1; 118 delete thread1;
119 delete thread2; 119 delete thread2;
120 } 120 }
OLDNEW
« no previous file with comments | « base/thread_unittest.cc ('k') | build/common.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698