blob: b79fe468cf359a644c3b3c9d2001b5c4330e3ab9 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
|
// Copyright (c) 2010 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
// Main function for large IE tests.
#include <atlbase.h>
#include <atlcom.h>
#include "base/at_exit.h"
#include "base/command_line.h"
#include "ceee/testing/utils/gflag_utils.h"
#include "ceee/testing/utils/nt_internals.h"
#include "chrome/common/url_constants.h"
#include "gmock/gmock.h"
#include "gtest/gtest.h"
// Stub for unittesting.
namespace ceee_module_util {
LONG LockModule() {
return 0;
}
LONG UnlockModule() {
return 0;
}
void Lock() {
}
void Unlock() {
}
void AddRefModuleWorkerThread() {
}
void ReleaseModuleWorkerThread() {
}
void FireEventToBroker(const std::string& event_name,
const std::string& event_args) {
}
} // namespace ceee_module_util
// We're testing some ATL code that requires a module object.
class ObligatoryModule: public CAtlDllModuleT<ObligatoryModule> {
};
ObligatoryModule g_obligatory_atl_module;
const DWORD kTestGFlags = FLG_USER_STACK_TRACE_DB |
FLG_ENABLE_HANDLE_EXCEPTIONS |
FLG_ENABLE_CLOSE_EXCEPTIONS |
FLG_HEAP_VALIDATE_PARAMETERS;
int main(int argc, char **argv) {
// Disabled, bb2560934.
// if (!IsDebuggerPresent())
// testing::RelaunchWithGFlags(kTestGFlags);
testing::InitGoogleMock(&argc, argv);
testing::InitGoogleTest(&argc, argv);
// Obligatory Chrome base initialization.
CommandLine::Init(argc, argv);
base::AtExitManager at_exit_manager;
// Needs to be called before we can use GURL.
chrome::RegisterChromeSchemes();
return RUN_ALL_TESTS();
}
|