Re: Review Request 43219: Added unit tests for hitting the /help endpoints of a process.

2016-02-04 Thread Ben Mahler

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/43219/#review117968
---


Fix it, then Ship it!





3rdparty/libprocess/src/tests/http_tests.cpp (lines 185 - 199)


Kevin and I discovered that this will fail during repeated runs because the 
help request gets made before the HttpProcess initialization completes. 

We added a dummy dispatch into the process in order to wait for 
initialization to complete.



3rdparty/libprocess/src/tests/http_tests.cpp (lines 185 - 186)


We tend to put variable declarations next to use, so these would go down to 
the first usage.



3rdparty/libprocess/src/tests/http_tests.cpp (line 220)


There is EXPECT_SOME to make this a bit easier.



3rdparty/libprocess/src/tests/http_tests.cpp (lines 256 - 257)


Let's switch these to EXPECT since the test can proceed if these fail.


- Ben Mahler


On Feb. 5, 2016, 3:24 a.m., Kevin Klues wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/43219/
> ---
> 
> (Updated Feb. 5, 2016, 3:24 a.m.)
> 
> 
> Review request for mesos and Ben Mahler.
> 
> 
> Bugs: MESOS-4552
> https://issues.apache.org/jira/browse/MESOS-4552
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> These unit tests make sure that help endpoints are up and
> running for a process's installed routes. They also ensure that
> deleting a process removes the help information for all of it's routes
> (to make sure stale information isn't sticking around if a new process
> comes along with the same id later).
> 
> 
> Diffs
> -
> 
>   3rdparty/libprocess/src/tests/http_tests.cpp 
> 66d185e3fd8a165d8a98d3d2752e756f8de3499b 
> 
> Diff: https://reviews.apache.org/r/43219/diff/
> 
> 
> Testing
> ---
> 
> This commit is a unit test that tests JSONification of the /help endpoint as 
> well as the removal of help strings after a process has been terminated.
> 
> GTEST_FILTER="HTTPTest.EndpointsHelp:HTTPTest.EndpointsHelpRemoval" make -j 
> check
> 
> 
> Thanks,
> 
> Kevin Klues
> 
>



Re: Review Request 43219: Added unit tests for hitting the /help endpoints of a process.

2016-02-04 Thread Kevin Klues

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/43219/
---

(Updated Feb. 5, 2016, 3:24 a.m.)


Review request for mesos and Ben Mahler.


Changes
---

Addressed comments by bmahler.


Bugs: MESOS-4552
https://issues.apache.org/jira/browse/MESOS-4552


Repository: mesos


Description
---

These unit tests make sure that help endpoints are up and
running for a process's installed routes. They also ensure that
deleting a process removes the help information for all of it's routes
(to make sure stale information isn't sticking around if a new process
comes along with the same id later).


Diffs (updated)
-

  3rdparty/libprocess/src/tests/http_tests.cpp 
66d185e3fd8a165d8a98d3d2752e756f8de3499b 

Diff: https://reviews.apache.org/r/43219/diff/


Testing (updated)
---

This commit is a unit test that tests JSONification of the /help endpoint as 
well as the removal of help strings after a process has been terminated.

GTEST_FILTER="HTTPTest.EndpointsHelp:HTTPTest.EndpointsHelpRemoval" make -j 
check


Thanks,

Kevin Klues