OpenStack Horizon: integration tests for plugins (part 2, CI)

It’s a small addition to my previous post. I don’t like to edit my previous posts. The only exception is when I have to fix some typos, spelling error, links, etc.

During the previous post, I described how to implement integration tests for the Horizon plugins, but I didn’t have enough time to implement and verify CI for it. It’s time to fix this.

We’ve got really awesome CI in the OpenStack. Zuul works great for OpenStack needs and allows to configure cross-project jobs. A big thank you to our Infra team for the help during CI setup.

We’ve got horizon-integration-tests job for Horizon itself. It means that everything you need is to extend it and add few config options.

Here is an example from this patch:

- job:
    name: vitrage-dashboard-integration-tests
    parent: horizon-integration-tests
    required-projects:
      - name: openstack/horizon
      - name: openstack/vitrage
      - name: openstack/python-vitrageclient
      - name: openstack/vitrage-dashboard
    roles:
      - zuul: openstack-infra/devstack
      - zuul: openstack/horizon
    irrelevant-files:
      - ^.*\.rst$
      - ^doc/.*$
      - ^releasenotes/.*$
    vars:
      devstack_plugins:
        vitrage: https://git.openstack.org/openstack/vitrage
        vitrage-dashboard: https://git.openstack.org/openstack/vitrage-dashboard
      devstack_services:
        horizon: true
      tox_envlist: integration

I’ll describe you the most important parts.

parent: horizon-integration-tests - you need to make your job as a child of the existing one, to not duplicate code and playbooks.

required-projects - just add your project and client here to the list. It’s a requirement on how our CI works. It lets Zuul clone repos before Devstack starts. Cloning repositories during Devstack setup is not allowed.

roles - devstack and horizon needed here to be configured explicitly. I really need to check if everything works without this section.

devstack_plugins and devstack_services - here you can configure your. plugins and enable or disable some services from the Devstack default configuration.

Tags

.net .net-framework .net-framework-3.5 agile ajax ajax-control-toolkit ampq ansible apache asp.net asp.net-mvc automation axum babel bash benchmark blog blog-engine bootstrap buildout c# cache centos chrome ci cinder ckan cli cloud code-review codeplex community config debugger deface dependencies development-environment devices devstack devtime disks django dlr dns docker dockerimage dos easy_install elmah encoding environment-variables error event events everything-as-a-code exception exceptions fabrik firefox flask foreach forms fstab gae gcc gerrit git github go google google-app-engine grep hack hacked hardware headless horizon hound html hugo iaas ienumerable iis internet iptables iron-python ironic iscsi java-script javascript jenkins jquery js jsx k8s kharkivpy kiss kombu kubernetes kvm kyiv lettuce libvirt linux lio loci logging loopback losetup lvm mac-os macos mercurial microsoft microsoft-sync-framework mobile mono ms-office msbuild networking news nginx npm npx offtopic oop open-source open-xml opensource openstack openvswitch os packages paraller-development patterns-practices performance php pika pip plugins pnp podcast popup postgresql profiler project protocols proxy pycamp pycharm pycon pykyiv pylint pypi python python-3 qcow quantum qumy rabbitmq rar react reactjs refactoring rfc rhel search-engine security selenium server shell silverlight socket software-engineering source-control sourcegear-vault sources sql sql-server sql-server-express sqlalchemy ssh static-site sublimetext svg tests tgt tipfy todo tornado typescript uapycon ui uneta unit-tests upgrades usability vim virtualenv visual-studio vitrage vm vue.js vuejs web-development web-server web-service web_root webpack webroot windows windows-live word-press x32 x64 xcode xml xss xvfb интернет-магазин книги

Recent posts

Go 1.18: new features

Всё будет Kubernetes

2022 Relaunch

Everyday Blogging

I don't want this CI


Archives

2022 (3)
2019 (73)
2018 (2)
2017 (3)
2016 (2)
2015 (3)
2014 (5)
2013 (17)
2012 (22)
2011 (36)
2010 (25)
2009 (35)
2008 (32)
2007 (2)