andreaspeters commented on a change in pull request #409:
URL: https://github.com/apache/mesos/pull/409#discussion_r716425552
##########
File path: src/python/cli_new/lib/cli/tests/base.py
##########
@@ -272,41 +274,33 @@ def launch(self, timeout=TIMEOUT):
super(Agent, self).launch()
Agent.count += 1
- try:
- # pylint: disable=missing-docstring
- def single_slave(data):
- return len(data["slaves"]) == 1
-
- http.get_json(self.flags["master"], "slaves", single_slave,
timeout)
- except Exception as exception:
+ data = http.get_json(self.flags["master"], "slaves", self.config)
+ if len(data["slaves"]) == 1:
Review comment:
yes, it is the same. But since the get_json function does not have the
condition, I have to change it a little.Before, the function single_slave() was
a parameter (condition) for get_json(). And in get_json there was a call for
condition.
No matter, I think the whole test never really worked before. I had a look
inside. The mesos-cli test even check if it's possible to start a task. But,
the mesos-cli cannot start a task. :man_shrugging: So, I think the whole test
should be rewritten. But thats nothing I will do at the moment.
What I'm doing is, I'm using mesos-cli by self at least some weeks long
before my PR.
--
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]