From 2906dffcdbd4398361d5d7f718faa4f24fdc3b8e Mon Sep 17 00:00:00 2001 From: Rahat Mahmood Date: Fri, 2 Aug 2019 12:51:23 -0700 Subject: Automated rollback of changelist 261191548 PiperOrigin-RevId: 261373749 --- test/syscalls/linux/socket_ip_tcp_generic.cc | 23 ----------------------- 1 file changed, 23 deletions(-) (limited to 'test') diff --git a/test/syscalls/linux/socket_ip_tcp_generic.cc b/test/syscalls/linux/socket_ip_tcp_generic.cc index 01987d2f0..a43cf9bce 100644 --- a/test/syscalls/linux/socket_ip_tcp_generic.cc +++ b/test/syscalls/linux/socket_ip_tcp_generic.cc @@ -697,28 +697,5 @@ TEST_P(TCPSocketPairTest, SetCongestionControlFailsForUnsupported) { EXPECT_EQ(0, memcmp(got_cc, old_cc, sizeof(old_cc))); } -TEST_P(TCPSocketPairTest, GetSockOptTCPInfo) { - auto sockets = ASSERT_NO_ERRNO_AND_VALUE(NewSocketPair()); - struct tcp_info info; - socklen_t optlen = sizeof(info); - ASSERT_THAT( - getsockopt(sockets->first_fd(), SOL_TCP, TCP_INFO, &info, &optlen), - SyscallSucceedsWithValue(0)); - EXPECT_EQ(optlen, sizeof(info)); - - EXPECT_EQ(info.tcpi_state, TCP_ESTABLISHED); - - EXPECT_GT(info.tcpi_rto, 0); - - // IPv4 MSS is 536 bytes by default, and IPv6 is 1220 bytes. - EXPECT_GE(info.tcpi_snd_mss, 536); - EXPECT_GE(info.tcpi_rcv_mss, 536); - EXPECT_GE(info.tcpi_advmss, 536); - - // MTU is typically 1500 for ethernet, but this is highly protocol - // dependent. Opt for a safe lower bound. - EXPECT_GT(info.tcpi_pmtu, 500); -} - } // namespace testing } // namespace gvisor -- cgit v1.2.3