OLD | NEW |
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 <atlbase.h> | 5 #include <atlbase.h> |
6 #include <atlcom.h> | 6 #include <atlcom.h> |
7 | 7 |
8 #include "base/string16.h" | 8 #include "base/strings/string16.h" |
9 #include "base/string_util.h" | 9 #include "base/strings/string_util.h" |
10 #include "base/strings/utf_string_conversions.h" | 10 #include "base/strings/utf_string_conversions.h" |
11 #include "base/win/scoped_bstr.h" | 11 #include "base/win/scoped_bstr.h" |
12 #include "base/win/scoped_comptr.h" | 12 #include "base/win/scoped_comptr.h" |
13 #include "chrome_frame/html_utils.h" | 13 #include "chrome_frame/html_utils.h" |
14 #include "chrome_frame/http_negotiate.h" | 14 #include "chrome_frame/http_negotiate.h" |
15 #include "chrome_frame/registry_list_preferences_holder.h" | 15 #include "chrome_frame/registry_list_preferences_holder.h" |
16 #include "chrome_frame/test/chrome_frame_test_utils.h" | 16 #include "chrome_frame/test/chrome_frame_test_utils.h" |
17 #include "chrome_frame/utils.h" | 17 #include "chrome_frame/utils.h" |
18 #include "gmock/gmock.h" | 18 #include "gmock/gmock.h" |
19 #include "gtest/gtest.h" | 19 #include "gtest/gtest.h" |
(...skipping 261 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
281 | 281 |
282 // Check additional headers are preserved. | 282 // Check additional headers are preserved. |
283 EXPECT_THAT(AppendCFUserAgentString(NULL, | 283 EXPECT_THAT(AppendCFUserAgentString(NULL, |
284 L"Authorization: A Zoo That I Ruin\r\n" | 284 L"Authorization: A Zoo That I Ruin\r\n" |
285 L"User-Agent: Get a Nurse;\r\n" | 285 L"User-Agent: Get a Nurse;\r\n" |
286 L"Accept-Language: Cleanup a Cat Egg\r\n"), | 286 L"Accept-Language: Cleanup a Cat Egg\r\n"), |
287 AllOf(ContainsRegex("User-Agent: Get a Nurse; chromeframe.+\r\n"), | 287 AllOf(ContainsRegex("User-Agent: Get a Nurse; chromeframe.+\r\n"), |
288 HasSubstr("Authorization: A Zoo That I Ruin\r\n"), | 288 HasSubstr("Authorization: A Zoo That I Ruin\r\n"), |
289 HasSubstr("Accept-Language: Cleanup a Cat Egg\r\n"))); | 289 HasSubstr("Accept-Language: Cleanup a Cat Egg\r\n"))); |
290 } | 290 } |
OLD | NEW |