launchpad-reviewers team mailing list archive
-
launchpad-reviewers team
-
Mailing list archive
-
Message #24750
[Merge] ~cjwatson/launchpad:fix-bulk-logtail-update into launchpad:master
Colin Watson has proposed merging ~cjwatson/launchpad:fix-bulk-logtail-update into launchpad:master.
Commit message:
Fix test failures in TestBinaryBuildPackageBehaviourBuildCollection
Requested reviews:
Launchpad code reviewers (launchpad-reviewers)
For more details, see:
https://code.launchpad.net/~cjwatson/launchpad/+git/launchpad/+merge/384280
These failed due to switching to performing build queue logtail updates in bulk.
--
Your team Launchpad code reviewers is requested to review the proposed merge of ~cjwatson/launchpad:fix-bulk-logtail-update into launchpad:master.
diff --git a/lib/lp/soyuz/tests/test_binarypackagebuildbehaviour.py b/lib/lp/soyuz/tests/test_binarypackagebuildbehaviour.py
index cc08bc5..db0b8ed 100644
--- a/lib/lp/soyuz/tests/test_binarypackagebuildbehaviour.py
+++ b/lib/lp/soyuz/tests/test_binarypackagebuildbehaviour.py
@@ -1,4 +1,4 @@
-# Copyright 2010-2019 Canonical Ltd. This software is licensed under the
+# Copyright 2010-2020 Canonical Ltd. This software is licensed under the
# GNU Affero General Public License version 3 (see the file LICENSE).
"""Tests for BinaryPackageBuildBehaviour."""
@@ -37,6 +37,7 @@ from lp.buildmaster.interfaces.builder import CannotBuild
from lp.buildmaster.interfaces.buildfarmjobbehaviour import (
IBuildFarmJobBehaviour,
)
+from lp.buildmaster.manager import BuilddManager
from lp.buildmaster.tests.mock_slaves import (
AbortingSlave,
BuildingSlave,
@@ -424,6 +425,7 @@ class TestBinaryBuildPackageBehaviourBuildCollection(TestCaseWithFactory):
switch_dbuser('testadmin')
self.builder = self.factory.makeBuilder()
+ self.manager = BuilddManager()
self.interactor = BuilderInteractor()
self.build = self.factory.makeBinaryPackageBuild(
builder=self.builder, pocket=PackagePublishingPocket.RELEASE)
@@ -442,7 +444,8 @@ class TestBinaryBuildPackageBehaviourBuildCollection(TestCaseWithFactory):
slave_status = yield slave.status()
yield self.interactor.updateBuild(
bf.getVitals('foo'), slave, slave_status, bf,
- self.interactor.getBuildBehaviour)
+ self.interactor.getBuildBehaviour, self.manager)
+ self.manager.flushLogTails()
def assertBuildProperties(self, build):
"""Check that a build happened by making sure some of its properties