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

Side by Side Diff: chrome/browser/install_verification/win/module_list_unittest.cc

Issue 1550593002: Switch to standard integer types in chrome/browser/, part 2 of 4. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 12 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
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 "chrome/browser/install_verification/win/module_list.h" 5 #include "chrome/browser/install_verification/win/module_list.h"
6 6
7 #include <stddef.h>
7 #include <Windows.h> 8 #include <Windows.h>
8 #include <vector> 9 #include <vector>
9 #include "base/bind.h" 10 #include "base/bind.h"
10 #include "base/bind_helpers.h" 11 #include "base/bind_helpers.h"
11 #include "base/callback_helpers.h" 12 #include "base/callback_helpers.h"
12 #include "base/memory/scoped_ptr.h" 13 #include "base/memory/scoped_ptr.h"
13 #include "chrome/browser/install_verification/win/loaded_modules_snapshot.h" 14 #include "chrome/browser/install_verification/win/loaded_modules_snapshot.h"
14 #include "testing/gtest/include/gtest/gtest.h" 15 #include "testing/gtest/include/gtest/gtest.h"
15 16
16 TEST(ModuleListTest, TestCase) { 17 TEST(ModuleListTest, TestCase) {
(...skipping 27 matching lines...) Expand all
44 // Reset module_list here. That should typically be the last ref on 45 // Reset module_list here. That should typically be the last ref on
45 // msvidc32.dll, so it will be unloaded now. 46 // msvidc32.dll, so it will be unloaded now.
46 module_list.reset(); 47 module_list.reset();
47 ASSERT_EQ(NULL, ::GetModuleHandle(L"msvidc32.dll")); 48 ASSERT_EQ(NULL, ::GetModuleHandle(L"msvidc32.dll"));
48 49
49 // List the modules from the stale snapshot (including a dangling HMODULE to 50 // List the modules from the stale snapshot (including a dangling HMODULE to
50 // msvidc32.dll), simulating a race condition. 51 // msvidc32.dll), simulating a race condition.
51 module_list = ModuleList::FromLoadedModuleSnapshot(snapshot); 52 module_list = ModuleList::FromLoadedModuleSnapshot(snapshot);
52 ASSERT_EQ(module_list->size(), original_list_size); 53 ASSERT_EQ(module_list->size(), original_list_size);
53 } 54 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698