Custom builders for each OS type
This commit is contained in:
parent
1e6918cb2b
commit
0036d1e131
|
@ -11,11 +11,15 @@ test/buildbot/master/master.cfg.sample
|
|||
test/buildbot/master/twistd.log
|
||||
test/buildbot/master/twistd.pid
|
||||
test/buildbot/master/state.sqlite
|
||||
test/buildbot/master/vagrant-*/
|
||||
test/buildbot/master/osx-*/
|
||||
test/buildbot/master/linux-*/
|
||||
test/buildbot/master/win-*/
|
||||
test/buildbot/slave/twistd.hostname
|
||||
test/buildbot/slave/twistd.log
|
||||
test/buildbot/slave/twistd.pid
|
||||
test/buildbot/slave/vagrant-*/
|
||||
test/buildbot/slave/osx-*/
|
||||
test/buildbot/slave/linux-*/
|
||||
test/buildbot/slave/win-*/
|
||||
Vagrantfile
|
||||
.vagrant
|
||||
|
||||
|
|
|
@ -23,17 +23,26 @@ def get_vagrant_builders(branch, slaves):
|
|||
This returns a list of the builders that represent the entire
|
||||
chain for a given branch (unit, acceptance, packaging builds).
|
||||
"""
|
||||
unit = BuilderConfig(
|
||||
name="vagrant-%s-unit" % branch,
|
||||
slavenames=[s.slavename for s in slaves],
|
||||
factory=make_vagrant_unit_factory(branch))
|
||||
platforms = ["linux", "osx", "win"]
|
||||
builders = []
|
||||
|
||||
acceptance = BuilderConfig(
|
||||
name="vagrant-%s-acceptance" % branch,
|
||||
slavenames=[s.slavename for s in slaves],
|
||||
factory=make_vagrant_acceptance_factory(branch))
|
||||
for platform in platforms:
|
||||
platform_slaves = [s.slavename for s in slaves if platform in s.slavename]
|
||||
|
||||
return [unit, acceptance]
|
||||
if len(platform_slaves) > 0:
|
||||
unit = BuilderConfig(
|
||||
name="%s-%s-unit" % (platform, branch),
|
||||
slavenames=platform_slaves,
|
||||
factory=make_vagrant_unit_factory(branch))
|
||||
|
||||
acceptance = BuilderConfig(
|
||||
name="%s-%s-acceptance" % (platform, branch),
|
||||
slavenames=platform_slaves,
|
||||
factory=make_vagrant_acceptance_factory(branch))
|
||||
|
||||
builders.extend([unit, acceptance])
|
||||
|
||||
return builders
|
||||
|
||||
def make_vagrant_unit_factory(branch):
|
||||
"""
|
||||
|
|
|
@ -8,15 +8,17 @@ from buildbot.schedulers.basic import (
|
|||
Dependent,
|
||||
SingleBranchScheduler)
|
||||
|
||||
def get_schedulers():
|
||||
def get_schedulers(builders):
|
||||
# Run the unit tests for master
|
||||
unit_builders = [b.name for b in builders if "unit" in b.name]
|
||||
master_unit = SingleBranchScheduler(name="master-unit",
|
||||
change_filter=ChangeFilter(branch="master"),
|
||||
treeStableTimer=60,
|
||||
builderNames=["vagrant-master-unit"])
|
||||
builderNames=unit_builders)
|
||||
|
||||
acceptance_builders = [b.name for b in builders if "acceptance" in b.name]
|
||||
master_acceptance = Dependent(name="master-acceptance",
|
||||
upstream=master_unit,
|
||||
builderNames=["vagrant-master-acceptance"])
|
||||
builderNames=acceptance_builders)
|
||||
|
||||
return [master_unit, master_acceptance]
|
||||
|
|
|
@ -63,5 +63,5 @@ c['slavePortnum'] = 9989
|
|||
c['slaves'] = get_slaves_from_config(options.slaves)
|
||||
c['status'] = get_status(options)
|
||||
c['builders'] = get_builders(c['slaves'])
|
||||
c['schedulers'] = get_schedulers()
|
||||
c['schedulers'] = get_schedulers(c['builders'])
|
||||
c['change_source'] = get_change_sources()
|
||||
|
|
Loading…
Reference in New Issue