Skip to content

Instantly share code, notes, and snippets.

@sochotnicky
Created July 16, 2019 12:07
Show Gist options
  • Select an option

  • Save sochotnicky/5cec6639d920e9ac668a0dca5f420e58 to your computer and use it in GitHub Desktop.

Select an option

Save sochotnicky/5cec6639d920e9ac668a0dca5f420e58 to your computer and use it in GitHub Desktop.
aqe_trigger.py
import yaml
from buildbot.plugins import steps, util
class AQETrigger(steps.Trigger):
def getSchedulersAndProperties(self):
bbconfig = self.getProperty("bbconfig", "{}")
ret = []
bbconfig = yaml.safe_load(bbconfig)
print(bbconfig)
if not bbconfig:
return ret
if 'checks' in bbconfig:
for check in bbconfig['checks']:
if 'tox' in check:
ret.append(
{
"sched_name": "tox",
"props_to_set":
{
"tox-env": check['tox']['env']
},
"unimportant": False
}
)
return ret
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment