OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 <stdio.h> | 5 #include <stdio.h> |
6 | 6 |
7 #include "base/environment.h" | 7 #include "base/environment.h" |
8 #include "base/files/file_path.h" | 8 #include "base/files/file_path.h" |
9 #include "base/files/file_util.h" | 9 #include "base/files/file_util.h" |
10 #include "base/files/scoped_temp_dir.h" | 10 #include "base/files/scoped_temp_dir.h" |
| 11 #include "base/memory/scoped_ptr.h" |
11 #include "base/path_service.h" | 12 #include "base/path_service.h" |
12 #include "base/win/scoped_handle.h" | 13 #include "base/win/scoped_handle.h" |
13 #include "base/win/windows_version.h" | 14 #include "base/win/windows_version.h" |
14 #include "sandbox/win/tests/common/controller.h" | 15 #include "sandbox/win/tests/common/controller.h" |
15 #include "testing/gtest/include/gtest/gtest.h" | 16 #include "testing/gtest/include/gtest/gtest.h" |
16 | 17 |
17 namespace sandbox { | 18 namespace sandbox { |
18 | 19 |
19 class AddressSanitizerTests : public ::testing::Test { | 20 class AddressSanitizerTests : public ::testing::Test { |
20 public: | 21 public: |
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
97 size_t last_slash = source_file_basename.find_last_of("/\\"); | 98 size_t last_slash = source_file_basename.find_last_of("/\\"); |
98 last_slash = last_slash == std::string::npos ? 0 : last_slash + 1; | 99 last_slash = last_slash == std::string::npos ? 0 : last_slash + 1; |
99 ASSERT_TRUE(strstr(data.c_str(), &source_file_basename[last_slash])) | 100 ASSERT_TRUE(strstr(data.c_str(), &source_file_basename[last_slash])) |
100 << "The stack trace doesn't have a correct filename:\n" << data; | 101 << "The stack trace doesn't have a correct filename:\n" << data; |
101 } else { | 102 } else { |
102 LOG(WARNING) << "Not an AddressSanitizer build, skipping the run."; | 103 LOG(WARNING) << "Not an AddressSanitizer build, skipping the run."; |
103 } | 104 } |
104 } | 105 } |
105 | 106 |
106 } | 107 } |
OLD | NEW |