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

Side by Side Diff: content/child/web_url_loader_impl_unittest.cc

Issue 2483793002: Mark WebURLResponse data size getters as ForTesting (Closed)
Patch Set: Created 4 years, 1 month 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
« no previous file with comments | « no previous file | third_party/WebKit/Source/platform/exported/WebURLResponse.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "content/child/web_url_loader_impl.h" 5 #include "content/child/web_url_loader_impl.h"
6 6
7 #include <stdint.h> 7 #include <stdint.h>
8 #include <string.h> 8 #include <string.h>
9 9
10 #include <utility> 10 #include <utility>
(...skipping 696 matching lines...) Expand 10 before | Expand all | Expand 10 after
707 sync_load_response.encoded_data_length = kEncodedDataLength; 707 sync_load_response.encoded_data_length = kEncodedDataLength;
708 dispatcher()->set_sync_load_response(sync_load_response); 708 dispatcher()->set_sync_load_response(sync_load_response);
709 709
710 blink::WebURLResponse response; 710 blink::WebURLResponse response;
711 blink::WebURLError error; 711 blink::WebURLError error;
712 blink::WebData data; 712 blink::WebData data;
713 int64_t encoded_data_length = 0; 713 int64_t encoded_data_length = 0;
714 client()->loader()->loadSynchronously(request, response, error, data, 714 client()->loader()->loadSynchronously(request, response, error, data,
715 encoded_data_length); 715 encoded_data_length);
716 716
717 EXPECT_EQ(kEncodedBodyLength, response.encodedBodyLength()); 717 EXPECT_EQ(kEncodedBodyLength, response.encodedBodyLengthForTesting());
718 EXPECT_EQ(kEncodedDataLength, encoded_data_length); 718 EXPECT_EQ(kEncodedDataLength, encoded_data_length);
719 int expected_decoded_body_length = strlen(kBodyData); 719 int expected_decoded_body_length = strlen(kBodyData);
720 EXPECT_EQ(expected_decoded_body_length, response.decodedBodyLength()); 720 EXPECT_EQ(expected_decoded_body_length,
721 response.decodedBodyLengthForTesting());
721 } 722 }
722 723
723 } // namespace 724 } // namespace
724 } // namespace content 725 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/platform/exported/WebURLResponse.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698