~launchpad-pqm/launchpad/devel

« back to all changes in this revision

Viewing changes to lib/lp/archiveuploader/tests/test_uploadprocessor.py

[r=allenap, bac, gmb, julian-edwards, wallyworld][bug=905853, 905855,
 906079] In buildmaster,
 always shift into a read-write database transaction access mode before
 updating PackageBuild statuses. Shift into read-write transactions in
 appropriate places in TranslationTemplatesBuildBehavior. Ensure that all
 lp.buildmaster tests to which it is relevant are running with
 BuilddManagerTestFixture.

Show diffs side-by-side

added added

removed removed

Lines of Context:
629
629
        from_addr, to_addrs, raw_msg = stub.test_emails.pop()
630
630
        foo_bar = "Foo Bar <foo.bar@canonical.com>"
631
631
        daniel = "Daniel Silverstone <daniel.silverstone@canonical.com>"
632
 
        self.assertEqual([e.strip() for e in to_addrs], [foo_bar, daniel])
 
632
        self.assertContentEqual(
 
633
            [foo_bar, daniel], [e.strip() for e in to_addrs])
633
634
        self.assertTrue(
634
635
            "NEW" in raw_msg, "Expected email containing 'NEW', got:\n%s"
635
636
            % raw_msg)
663
664
        from_addr, to_addrs, raw_msg = stub.test_emails.pop()
664
665
        daniel = "Daniel Silverstone <daniel.silverstone@canonical.com>"
665
666
        foo_bar = "Foo Bar <foo.bar@canonical.com>"
666
 
        self.assertEqual([e.strip() for e in to_addrs], [foo_bar, daniel])
 
667
        self.assertContentEqual(
 
668
            [foo_bar, daniel], [e.strip() for e in to_addrs])
667
669
        self.assertTrue("Waiting for approval" in raw_msg,
668
670
                        "Expected an 'upload awaits approval' email.\n"
669
671
                        "Got:\n%s" % raw_msg)