Exemplo n.º 1
0
def _combine_details(detailses):
    """
    Take a sequence of details dictionaries and combine them into one.
    """
    # XXX: Only necessary becaause testtools's `gather_details` is perversely
    # mutatey.
    result = {}
    for details in detailses:
        gather_details(details, result)
    return pmap(result)
Exemplo n.º 2
0
def _combine_details(detailses):
    """
    Take a sequence of details dictionaries and combine them into one.
    """
    # XXX: Only necessary becaause testtools's `gather_details` is perversely
    # mutatey.
    result = {}
    for details in detailses:
        gather_details(details, result)
    return pmap(result)
Exemplo n.º 3
0
 def test_start_check_shutdown(self):
     # The fixture correctly starts and stops BIND.
     with BINDServer() as fixture:
         try:
             result = dig_call(fixture.config.port)
             self.assertIn("Got answer", result)
         except Exception:
             # self.useFixture() is not being used because we want to
             # handle the fixture's lifecycle, so we must also be
             # responsible for propagating fixture details.
             gather_details(fixture.getDetails(), self.getDetails())
             raise
     self.assertFalse(fixture.runner.is_running())
Exemplo n.º 4
0
 def test_start_check_shutdown(self):
     # The fixture correctly starts and stops BIND.
     with BINDServer() as fixture:
         try:
             result = dig_call(fixture.config.port)
             self.assertIn("Got answer", result)
         except Exception:
             # self.useFixture() is not being used because we want to
             # handle the fixture's lifecycle, so we must also be
             # responsible for propagating fixture details.
             gather_details(fixture.getDetails(), self.getDetails())
             raise
     self.assertFalse(fixture.runner.is_running())