Repository: mesos Updated Branches: refs/heads/master ec3318e20 -> b3c18d6d6
Removed unnecessary std:: prefix in http_api_tests.cpp. Project: http://git-wip-us.apache.org/repos/asf/mesos/repo Commit: http://git-wip-us.apache.org/repos/asf/mesos/commit/fe7f2f3b Tree: http://git-wip-us.apache.org/repos/asf/mesos/tree/fe7f2f3b Diff: http://git-wip-us.apache.org/repos/asf/mesos/diff/fe7f2f3b Branch: refs/heads/master Commit: fe7f2f3b680a07bcbbccd9b51aeeb93561e1627f Parents: 61f71f0 Author: Benjamin Mahler <[email protected]> Authored: Thu Aug 13 11:11:09 2015 -0700 Committer: Benjamin Mahler <[email protected]> Committed: Thu Aug 13 11:52:56 2015 -0700 ---------------------------------------------------------------------- src/tests/http_api_tests.cpp | 22 ++++++++++------------ 1 file changed, 10 insertions(+), 12 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/mesos/blob/fe7f2f3b/src/tests/http_api_tests.cpp ---------------------------------------------------------------------- diff --git a/src/tests/http_api_tests.cpp b/src/tests/http_api_tests.cpp index a51231e..044bca9 100644 --- a/src/tests/http_api_tests.cpp +++ b/src/tests/http_api_tests.cpp @@ -79,9 +79,7 @@ class HttpApiTest public: // TODO(anand): Use the serialize/deserialize from common/http.hpp // when they are available. - Try<Event> deserialize( - const std::string& contentType, - const std::string& body) + Try<Event> deserialize(const string& contentType, const string& body) { if (contentType == APPLICATION_PROTOBUF) { Event event; @@ -96,7 +94,7 @@ public: return parse; } - std::string serialize(const Call& call, const std::string& contentType) + string serialize(const Call& call, const string& contentType) { if (contentType == APPLICATION_PROTOBUF) { return call.SerializeAsString(); @@ -207,9 +205,9 @@ TEST_P(HttpApiTest, MalformedContent) Try<PID<Master>> master = StartMaster(flags); ASSERT_SOME(master); - const std::string body = "MALFORMED_CONTENT"; + const string body = "MALFORMED_CONTENT"; - const std::string contentType = GetParam(); + const string contentType = GetParam(); hashmap<string, string> headers; headers["Accept"] = contentType; @@ -235,7 +233,7 @@ TEST_P(HttpApiTest, UnsupportedContentMediaType) Try<PID<Master>> master = StartMaster(flags); ASSERT_SOME(master); - const std::string contentType = GetParam(); + const string contentType = GetParam(); hashmap<string, string> headers; headers["Accept"] = contentType; @@ -245,7 +243,7 @@ TEST_P(HttpApiTest, UnsupportedContentMediaType) Call::Subscribe* subscribe = call.mutable_subscribe(); subscribe->mutable_framework_info()->CopyFrom(DEFAULT_V1_FRAMEWORK_INFO); - const std::string unknownMediaType = "application/unknown-media-type"; + const string unknownMediaType = "application/unknown-media-type"; Future<Response> response = process::http::post( master.get(), @@ -277,7 +275,7 @@ TEST_P(HttpApiTest, Subscribe) subscribe->mutable_framework_info()->CopyFrom(DEFAULT_V1_FRAMEWORK_INFO); // Retrieve the parameter passed as content type to this test. - const std::string contentType = GetParam(); + const string contentType = GetParam(); hashmap<string, string> headers; headers["Accept"] = contentType; @@ -347,7 +345,7 @@ TEST_P(HttpApiTest, SubscribedOnRetryWithForce) subscribe->mutable_framework_info()->CopyFrom(DEFAULT_V1_FRAMEWORK_INFO); // Retrieve the parameter passed as content type to this test. - const std::string contentType = GetParam(); + const string contentType = GetParam(); hashmap<string, string> headers; headers["Accept"] = contentType; @@ -472,7 +470,7 @@ TEST_P(HttpApiTest, UpdatePidToHttpScheduler) subscribe->set_force(true); // Retrieve the parameter passed as content type to this test. - const std::string contentType = GetParam(); + const string contentType = GetParam(); hashmap<string, string> headers; headers["Accept"] = contentType; @@ -559,7 +557,7 @@ TEST_P(HttpApiTest, UpdatePidToHttpSchedulerWithoutForce) CopyFrom(evolve(frameworkId.get())); // Retrieve the parameter passed as content type to this test. - const std::string contentType = GetParam(); + const string contentType = GetParam(); hashmap<string, string> headers; headers["Accept"] = contentType;
