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

Side by Side Diff: content/public/test/unittest_test_suite.cc

Issue 2867693004: Snapshot of all changes to get jumbo in blink and content.
Patch Set: Exclude certain files from jumbo because of a Windows problem Created 3 years, 3 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 | « content/public/renderer/BUILD.gn ('k') | content/renderer/BUILD.gn » ('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) 2012 The Chromium Authors. All rights reserved. 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 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 "content/public/test/unittest_test_suite.h" 5 #include "content/public/test/unittest_test_suite.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "base/rand_util.h" 8 #include "base/rand_util.h"
9 #include "base/test/test_suite.h" 9 #include "base/test/test_suite.h"
10 #include "build/build_config.h" 10 #include "build/build_config.h"
11 #include "content/test/test_blink_web_unit_test_support.h" 11 #include "content/test/test_blink_web_unit_test_support.h"
12 #include "third_party/WebKit/public/web/WebKit.h" 12 #include "third_party/WebKit/public/web/WebKit.h"
13 13
14 #if defined(USE_AURA) 14 #if defined(USE_AURA)
15 #include "ui/aura/env.h" 15 #include "ui/aura/env.h"
16 #endif 16 #endif
17 17
18 #if defined(USE_X11) 18 #if defined(USE_X11)
19 #include <X11/Xlib.h> 19 #include <X11/Xlib.h>
20 #undef None // Defined by X11/X.h to 0L which collides with other headers
20 #endif 21 #endif
21 22
22 namespace content { 23 namespace content {
23 24
24 UnitTestTestSuite::UnitTestTestSuite(base::TestSuite* test_suite) 25 UnitTestTestSuite::UnitTestTestSuite(base::TestSuite* test_suite)
25 : test_suite_(test_suite) { 26 : test_suite_(test_suite) {
26 #if defined(USE_X11) 27 #if defined(USE_X11)
27 XInitThreads(); 28 XInitThreads();
28 #endif 29 #endif
29 #if defined(USE_AURA) 30 #if defined(USE_AURA)
30 DCHECK(!aura::Env::GetInstanceDontCreate()); 31 DCHECK(!aura::Env::GetInstanceDontCreate());
31 env_ = aura::Env::CreateInstance(); 32 env_ = aura::Env::CreateInstance();
32 #endif 33 #endif
33 DCHECK(test_suite); 34 DCHECK(test_suite);
34 blink_test_support_.reset(new TestBlinkWebUnitTestSupport); 35 blink_test_support_.reset(new TestBlinkWebUnitTestSupport);
35 } 36 }
36 37
37 UnitTestTestSuite::~UnitTestTestSuite() { 38 UnitTestTestSuite::~UnitTestTestSuite() {
38 blink_test_support_.reset(); 39 blink_test_support_.reset();
39 #if defined(USE_AURA) 40 #if defined(USE_AURA)
40 env_.reset(); 41 env_.reset();
41 #endif 42 #endif
42 } 43 }
43 44
44 int UnitTestTestSuite::Run() { 45 int UnitTestTestSuite::Run() {
45 return test_suite_->Run(); 46 return test_suite_->Run();
46 } 47 }
47 48
48 } // namespace content 49 } // namespace content
OLDNEW
« no previous file with comments | « content/public/renderer/BUILD.gn ('k') | content/renderer/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698