~launchpad-pqm/launchpad/devel

« back to all changes in this revision

Viewing changes to lib/lp/services/rabbit/tests/test_fixture.py

[r=allenap][bug=788557] In the RabbitMQ fixture don't double fork
 (and use subprocess),
 ensure SIGPIPE behaviour is returned to the default in spawned processes,
 and avoid the cookie race between the RabbitMQ daemon and rabbitmqctl.

Show diffs side-by-side

added added

removed removed

Lines of Context:
58
58
class TestRabbitFixture(TestCase):
59
59
 
60
60
    def test_start_check_shutdown(self):
61
 
        # XXX: GavinPanella 2011-05-26 bug=788557 : Disabled due to spurious
62
 
        # failures (cannot create cookie file).
63
 
        self.skip("Disabled (bug 788557)")
64
 
 
65
61
        # Rabbit needs to fully isolate itself: an existing per user
66
62
        # .erlange.cookie has to be ignored, and ditto bogus HOME if other
67
63
        # tests fail to cleanup.
79
75
                    }
80
76
                amqp.Connection(**connect_arguments).close()
81
77
                # And get a log file.
82
 
                log = fixture.runner.getDetails()["rabbit.log"]
 
78
                log = fixture.runner.getDetails()["server.log"]
83
79
                # Which shouldn't blow up on iteration.
84
80
                list(log.iter_text())
85
81
        except: