You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mesos.apache.org by an...@apache.org on 2016/12/05 18:12:09 UTC

[2/4] mesos git commit: Cleaned up the 'IOSwitchboard.RedirectLog' test.

Cleaned up the 'IOSwitchboard.RedirectLog' test.

Review: https://reviews.apache.org/r/54347/


Project: http://git-wip-us.apache.org/repos/asf/mesos/repo
Commit: http://git-wip-us.apache.org/repos/asf/mesos/commit/02d816e2
Tree: http://git-wip-us.apache.org/repos/asf/mesos/tree/02d816e2
Diff: http://git-wip-us.apache.org/repos/asf/mesos/diff/02d816e2

Branch: refs/heads/master
Commit: 02d816e297b4ab0ac3e8ec89ba3d89362c30e587
Parents: d90ea53
Author: Kevin Klues <kl...@gmail.com>
Authored: Mon Dec 5 09:40:30 2016 -0800
Committer: Anand Mazumdar <an...@apache.org>
Committed: Mon Dec 5 09:40:30 2016 -0800

----------------------------------------------------------------------
 src/tests/containerizer/io_switchboard_tests.cpp | 10 +++++++---
 1 file changed, 7 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/mesos/blob/02d816e2/src/tests/containerizer/io_switchboard_tests.cpp
----------------------------------------------------------------------
diff --git a/src/tests/containerizer/io_switchboard_tests.cpp b/src/tests/containerizer/io_switchboard_tests.cpp
index ebf9bc7..131ca94 100644
--- a/src/tests/containerizer/io_switchboard_tests.cpp
+++ b/src/tests/containerizer/io_switchboard_tests.cpp
@@ -233,9 +233,10 @@ TEST_F(IOSwitchboardServerTest, ServerAttachOutput)
 
   http::Request request;
   request.method = "POST";
-  request.url = http::URL("http", "", 80, "/");
+  request.url.domain = "";
+  request.url.path = "/";
   request.keepAlive = true;
-  request.headers["Accept"] = APPLICATION_JSON;
+  request.headers["Accept"] = APPLICATION_STREAMING_JSON;
   request.headers["Content-Type"] = APPLICATION_JSON;
   request.body = stringify(JSON::protobuf(call));
 
@@ -244,8 +245,8 @@ TEST_F(IOSwitchboardServerTest, ServerAttachOutput)
 
   Future<http::Connection> _connection = http::connect(address.get());
   AWAIT_READY(_connection);
-
   http::Connection connection = _connection.get();
+
   Future<http::Response> response = connection.send(request, true);
 
   AWAIT_EXPECT_RESPONSE_STATUS_EQ(http::OK().status, response);
@@ -293,6 +294,9 @@ TEST_F(IOSwitchboardServerTest, ServerAttachOutput)
     }
   }
 
+  AWAIT_READY(connection.disconnect());
+  AWAIT_READY(connection.disconnected());
+
   AWAIT_ASSERT_READY(runServer);
 
   os::close(nullFd.get());