OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 <windows.h> | 5 #include <windows.h> |
6 | 6 |
7 #include "base/file_path.h" | 7 #include "base/file_path.h" |
8 #include "base/memory/scoped_temp_dir.h" | |
9 #include "base/path_service.h" | 8 #include "base/path_service.h" |
| 9 #include "base/scoped_temp_dir.h" |
10 #include "chrome/installer/mini_installer/decompress.h" | 10 #include "chrome/installer/mini_installer/decompress.h" |
11 #include "testing/gtest/include/gtest/gtest.h" | 11 #include "testing/gtest/include/gtest/gtest.h" |
12 | 12 |
13 class MiniDecompressTest : public testing::Test { | 13 class MiniDecompressTest : public testing::Test { |
14 protected: | 14 protected: |
15 virtual void SetUp() { | 15 virtual void SetUp() { |
16 } | 16 } |
17 virtual void TearDown() { | 17 virtual void TearDown() { |
18 } | 18 } |
19 }; | 19 }; |
(...skipping 15 matching lines...) Expand all Loading... |
35 | 35 |
36 // Decompress our test file. | 36 // Decompress our test file. |
37 EXPECT_TRUE(mini_installer::Expand(source_path.value().c_str(), | 37 EXPECT_TRUE(mini_installer::Expand(source_path.value().c_str(), |
38 dest_path.value().c_str())); | 38 dest_path.value().c_str())); |
39 | 39 |
40 // Check if the expanded file is a valid executable. | 40 // Check if the expanded file is a valid executable. |
41 DWORD type = static_cast<DWORD>(-1); | 41 DWORD type = static_cast<DWORD>(-1); |
42 EXPECT_TRUE(GetBinaryType(dest_path.value().c_str(), &type)); | 42 EXPECT_TRUE(GetBinaryType(dest_path.value().c_str(), &type)); |
43 EXPECT_EQ(SCS_32BIT_BINARY, type); | 43 EXPECT_EQ(SCS_32BIT_BINARY, type); |
44 } | 44 } |
OLD | NEW |