launchpad-reviewers team mailing list archive
-
launchpad-reviewers team
-
Mailing list archive
-
Message #01155
[Merge] lp:~mars/launchpad/rollback-11586-and-11588 into lp:launchpad/devel
Māris Fogels has proposed merging lp:~mars/launchpad/rollback-11586-and-11588 into lp:launchpad/devel.
Requested reviews:
Launchpad code reviewers (launchpad-reviewers)
This branch rolls back revisions 11586 and 11588 in order to fix buildbot.
--
https://code.launchpad.net/~mars/launchpad/rollback-11586-and-11588/+merge/36212
Your team Launchpad code reviewers is requested to review the proposed merge of lp:~mars/launchpad/rollback-11586-and-11588 into lp:launchpad/devel.
=== modified file 'lib/lp/buildmaster/tests/test_builder.py'
--- lib/lp/buildmaster/tests/test_builder.py 2010-09-21 16:23:35 +0000
+++ lib/lp/buildmaster/tests/test_builder.py 2010-09-21 20:57:44 +0000
@@ -555,11 +555,11 @@
def test_clean(self):
slave = self.getClientSlave()
- # XXX: JonathanLange 2010-09-21: Calling clean() on the slave requires
- # it to be in either the WAITING or ABORTED states, and both of these
- # states are very difficult to achieve in a test environment. For the
- # time being, we'll just assert that a clean attribute exists.
- self.assertNotEqual(getattr(slave, 'clean', None), None)
+ # clean() only works when in aborted / waiting state.
+ self.triggerGoodBuild(slave)
+ slave.abort()
+ result = slave.clean()
+ self.assertEqual(BuilderStatus.IDLE, result)
def test_echo(self):
# Calling 'echo' contacts the server which returns the arguments we
=== modified file 'lib/lp/soyuz/tests/test_archive.py'
--- lib/lp/soyuz/tests/test_archive.py 2010-09-21 11:08:26 +0000
+++ lib/lp/soyuz/tests/test_archive.py 2010-09-21 20:57:44 +0000
@@ -355,9 +355,8 @@
# Enabling an archive should set all the Archive's suspended builds to
# WAITING.
archive = self.factory.makeArchive(enabled=True)
- build = self.factory.makeBinaryPackageBuild(
+ self.factory.makeBinaryPackageBuild(
archive=archive, status=BuildStatus.NEEDSBUILD)
- build.queueBuild()
# disable the archive, as it is currently enabled
removeSecurityProxy(archive).disable()
self.assertHasBuildJobsWithStatus(archive, JobStatus.SUSPENDED, 1)
@@ -374,9 +373,8 @@
# Disabling an archive should set all the Archive's pending bulds to
# SUSPENDED.
archive = self.factory.makeArchive(enabled=True)
- build = self.factory.makeBinaryPackageBuild(
+ self.factory.makeBinaryPackageBuild(
archive=archive, status=BuildStatus.NEEDSBUILD)
- build.queueBuild()
self.assertHasBuildJobsWithStatus(archive, JobStatus.WAITING, 1)
removeSecurityProxy(archive).disable()
self.assertNoBuildJobsHaveStatus(archive, JobStatus.WAITING)
=== modified file 'lib/lp/testing/factory.py'
--- lib/lp/testing/factory.py 2010-09-21 11:45:15 +0000
+++ lib/lp/testing/factory.py 2010-09-21 20:57:44 +0000
@@ -1900,7 +1900,7 @@
if difference_type is not (
DistroSeriesDifferenceType.MISSING_FROM_DERIVED_SERIES):
- self.makeSourcePackagePublishingHistory(
+ source_pub = self.makeSourcePackagePublishingHistory(
distroseries=derived_series,
version=versions.get('derived'),
sourcepackagename=source_package_name,
@@ -1909,7 +1909,7 @@
if difference_type is not (
DistroSeriesDifferenceType.UNIQUE_TO_DERIVED_SERIES):
- self.makeSourcePackagePublishingHistory(
+ source_pub = self.makeSourcePackagePublishingHistory(
distroseries=derived_series.parent_series,
version=versions.get('parent'),
sourcepackagename=source_package_name,
@@ -2666,6 +2666,10 @@
date_created=self.getUniqueDate())
naked_build = removeSecurityProxy(binary_package_build)
naked_build.builder = builder
+ binary_package_build_job = naked_build.makeJob()
+ BuildQueue(
+ job=binary_package_build_job.job,
+ job_type=BuildFarmJobType.PACKAGEBUILD)
return binary_package_build
def makeSourcePackagePublishingHistory(self, sourcepackagename=None,
=== modified file 'lib/lp/testing/tests/test_factory.py'
--- lib/lp/testing/tests/test_factory.py 2010-09-21 11:08:26 +0000
+++ lib/lp/testing/tests/test_factory.py 2010-09-21 20:57:44 +0000
@@ -113,12 +113,6 @@
status=BuildStatus.FULLYBUILT)
self.assertEqual(BuildStatus.FULLYBUILT, bpb.status)
- def test_makeBinaryPackageBuild_can_be_queued(self):
- build = self.factory.makeBinaryPackageBuild()
- # Just check that makeBinaryPackageBuild returns a build that can be
- # queued.
- build.queueBuild()
-
# makeBinaryPackageName
def test_makeBinaryPackageName_returns_proxied_IBinaryPackageName(self):
binarypackagename = self.factory.makeBinaryPackageName()