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 #import "ios/web/public/test/response_providers/file_based_response_provider_imp
l.h" | 5 #import "ios/web/public/test/http_server/file_based_response_provider_impl.h" |
6 | 6 |
7 #include "base/files/file_util.h" | 7 #include "base/files/file_util.h" |
8 #import "ios/web/public/test/response_providers/response_provider.h" | 8 #import "ios/web/public/test/http_server/response_provider.h" |
9 #include "url/gurl.h" | 9 #include "url/gurl.h" |
10 | 10 |
11 namespace web { | 11 namespace web { |
12 | 12 |
13 FileBasedResponseProviderImpl::FileBasedResponseProviderImpl( | 13 FileBasedResponseProviderImpl::FileBasedResponseProviderImpl( |
14 const base::FilePath& path) | 14 const base::FilePath& path) |
15 : path_(path) {} | 15 : path_(path) {} |
16 | 16 |
17 FileBasedResponseProviderImpl::~FileBasedResponseProviderImpl() {} | 17 FileBasedResponseProviderImpl::~FileBasedResponseProviderImpl() {} |
18 | 18 |
(...skipping 12 matching lines...) Expand all Loading... |
31 // Remove the leading slash in url path. | 31 // Remove the leading slash in url path. |
32 if (url_path.length() > 0 && url_path[0] == '/') { | 32 if (url_path.length() > 0 && url_path[0] == '/') { |
33 url_path.erase(0, 1); | 33 url_path.erase(0, 1); |
34 } | 34 } |
35 if (!url_path.empty()) | 35 if (!url_path.empty()) |
36 result = result.Append(url_path); | 36 result = result.Append(url_path); |
37 return result; | 37 return result; |
38 } | 38 } |
39 | 39 |
40 } // namespace web | 40 } // namespace web |
OLD | NEW |