libhttp_unittests_SOURCES += http_server_test.h
libhttp_unittests_SOURCES += http_server_unittests.cc
if HAVE_OPENSSL
+libhttp_unittests_SOURCES += tls_response_creator_test.h
libhttp_unittests_SOURCES += tls_server_unittests.cc
libhttp_unittests_SOURCES += tls_client_unittests.cc
endif
io_service_->stop();
}
- // We should have 1 connect.
+ // We should have 2 connects.
EXPECT_EQ(2, monitor.connect_cnt_);
// We should have 2 handshakes when TLS is enabled.
if (client_context_) {
EXPECT_EQ(2, monitor.handshake_cnt_);
}
- // We should have 0 closes
+ // We should have 1 close.
EXPECT_EQ(1, monitor.close_cnt_);
// We should have a valid fd.
ASSERT_GT(monitor.registered_fd_, -1);
ASSERT_TRUE(client->isConnectionAlive());
// Run IO service for 1000ms. The idle time is set to 500ms, so
- // the connection should be closed by the server while we wait here.
+ // the connection should be closed by the server while we wait here.
runIOService(1000);
// Make sure the connection has been closed.
testListen();
}
-
// This test verifies that persistent HTTP connection can be established when
// "Connection: Keep-Alive" header value is specified.
TEST_F(HttpsListenerTest, keepAlive) {