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

Side by Side Diff: base/sequence_checker_unittest.cc

Issue 11550031: Implement SequenceChecker, which is a generalization of ThreadChecker (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Address comments Created 8 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "base/sequence_checker.h"
6
7 #include <cstddef>
8
9 #include "base/compiler_specific.h"
10 #include "base/memory/ref_counted.h"
11 #include "base/test/null_task_runner.h"
12 #include "testing/gtest/include/gtest/gtest.h"
13
14 namespace base {
15
16 namespace {
17
18 // Call various methods of SequenceChecker to make sure nothing blows
19 // up in either debug or release mode.
20 TEST(SequenceCheckerTest, Basic) {
21 SequenceChecker sequence_checker(new NullTaskRunner());
22 sequence_checker.CalledOnValidSequence();
23 sequence_checker.ChangeSequence(NULL);
24 sequence_checker.CalledOnValidSequence();
25 }
26
27 } // namespace
28
29 } // namespace base
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698