lidavidm commented on a change in pull request #12628:
URL: https://github.com/apache/arrow/pull/12628#discussion_r826969654



##########
File path: cpp/src/arrow/flight/test_definitions.cc
##########
@@ -91,6 +91,23 @@ void ConnectivityTest::TestShutdownWithDeadline() {
   ASSERT_OK(server->Shutdown(&deadline));
   ASSERT_OK(server->Wait());
 }
+void ConnectivityTest::TestBrokenConnection() {
+  std::unique_ptr<FlightServerBase> server = ExampleTestServer();
+  ASSERT_OK_AND_ASSIGN(auto location, Location::ForScheme(transport(), 
"localhost", 0));
+  FlightServerOptions options(location);
+  ASSERT_OK(server->Init(options));
+
+  std::unique_ptr<FlightClient> client;
+  ASSERT_OK_AND_ASSIGN(location,
+                       Location::ForScheme(transport(), "localhost", 
server->port()));
+  ASSERT_OK(FlightClient::Connect(location, &client));
+
+  ASSERT_OK(server->Shutdown());
+  ASSERT_OK(server->Wait());
+
+  std::unique_ptr<FlightInfo> info;
+  ASSERT_FALSE(client->GetFlightInfo(FlightDescriptor::Command(""), 
&info).ok());

Review comment:
       Changed to test for IOError.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to