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

Side by Side Diff: net/ftp/ftp_network_transaction_unittest.cc

Issue 903273002: Update from https://crrev.com/315085 (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 10 months 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 | « net/ftp/ftp_network_transaction.cc ('k') | net/http/http_atom_list.h » ('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 (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 "net/ftp/ftp_network_transaction.h" 5 #include "net/ftp/ftp_network_transaction.h"
6 6
7 #include "build/build_config.h" 7 #include "build/build_config.h"
8 8
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "base/memory/ref_counted.h" 10 #include "base/memory/ref_counted.h"
(...skipping 900 matching lines...) Expand 10 before | Expand all | Expand 10 after
911 TEST_P(FtpNetworkTransactionTest, DirectoryTransactionWithPasvFallback) { 911 TEST_P(FtpNetworkTransactionTest, DirectoryTransactionWithPasvFallback) {
912 FtpSocketDataProviderDirectoryListingWithPasvFallback ctrl_socket; 912 FtpSocketDataProviderDirectoryListingWithPasvFallback ctrl_socket;
913 ExecuteTransaction(&ctrl_socket, "ftp://host", OK); 913 ExecuteTransaction(&ctrl_socket, "ftp://host", OK);
914 914
915 EXPECT_TRUE(transaction_.GetResponseInfo()->is_directory_listing); 915 EXPECT_TRUE(transaction_.GetResponseInfo()->is_directory_listing);
916 EXPECT_EQ(-1, transaction_.GetResponseInfo()->expected_content_size); 916 EXPECT_EQ(-1, transaction_.GetResponseInfo()->expected_content_size);
917 } 917 }
918 918
919 TEST_P(FtpNetworkTransactionTest, DirectoryTransactionWithTypecode) { 919 TEST_P(FtpNetworkTransactionTest, DirectoryTransactionWithTypecode) {
920 FtpSocketDataProviderDirectoryListing ctrl_socket; 920 FtpSocketDataProviderDirectoryListing ctrl_socket;
921 ExecuteTransaction(&ctrl_socket, "ftp://host;type=d", OK); 921 ExecuteTransaction(&ctrl_socket, "ftp://host/;type=d", OK);
922 922
923 EXPECT_TRUE(transaction_.GetResponseInfo()->is_directory_listing); 923 EXPECT_TRUE(transaction_.GetResponseInfo()->is_directory_listing);
924 EXPECT_EQ(-1, transaction_.GetResponseInfo()->expected_content_size); 924 EXPECT_EQ(-1, transaction_.GetResponseInfo()->expected_content_size);
925 } 925 }
926 926
927 TEST_P(FtpNetworkTransactionTest, DirectoryTransactionMultilineWelcome) { 927 TEST_P(FtpNetworkTransactionTest, DirectoryTransactionMultilineWelcome) {
928 FtpSocketDataProviderDirectoryListing ctrl_socket; 928 FtpSocketDataProviderDirectoryListing ctrl_socket;
929 ctrl_socket.set_multiline_welcome(true); 929 ctrl_socket.set_multiline_welcome(true);
930 ExecuteTransaction(&ctrl_socket, "ftp://host", OK); 930 ExecuteTransaction(&ctrl_socket, "ftp://host", OK);
931 } 931 }
(...skipping 638 matching lines...) Expand 10 before | Expand all | Expand 10 after
1570 FtpSocketDataProvider::PRE_TYPE, 1570 FtpSocketDataProvider::PRE_TYPE,
1571 "257 \"\"\r\n", 1571 "257 \"\"\r\n",
1572 OK); 1572 OK);
1573 } 1573 }
1574 1574
1575 INSTANTIATE_TEST_CASE_P(FTP, 1575 INSTANTIATE_TEST_CASE_P(FTP,
1576 FtpNetworkTransactionTest, 1576 FtpNetworkTransactionTest,
1577 ::testing::Values(AF_INET, AF_INET6)); 1577 ::testing::Values(AF_INET, AF_INET6));
1578 1578
1579 } // namespace net 1579 } // namespace net
OLDNEW
« no previous file with comments | « net/ftp/ftp_network_transaction.cc ('k') | net/http/http_atom_list.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698