undercloud_deploy.py missing unit tests

Bug #1757230 reported by Jill Rouleau
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
tripleo
Fix Released
Medium
Jill Rouleau

Bug Description

Ansible-related functions lack unit tests, making it easy to miss breaking changes early in the dev cycle. Test coverage should be added for DeployUndercloud._download_ansible_playbooks, DeployUndercloud._launch_ansible, and DeployUndercloud.take_action. Tests should expose the breakage introduced by https://review.openstack.org/#/c/550577/2 for example.

http://logs.openstack.org/77/550577/2/check/tripleo-ci-centos-7-undercloud-containers/5997ba5/logs/undercloud/home/zuul/undercloud_install.log.txt.gz
2018-03-16 21:27:46 | ['Traceback (most recent call last):\n', ' File "/usr/lib/python2.7/site-packages/tripleoclient/v1/undercloud_deploy.py", line 582, in take_action\n parsed_args.output_dir)\n', ' File "/usr/lib/python2.7/site-packages/tripleoclient/v1/undercloud_deploy.py", line 415, in _download_ansible_playbooks\n key=os.path.getctime)\n', 'ValueError: max() arg is an empty sequence\n']

Changed in tripleo:
importance: Undecided → Medium
tags: added: tech-debt
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to python-tripleoclient (master)

Fix proposed to branch: master
Review: https://review.openstack.org/555456

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to python-tripleoclient (master)

Reviewed: https://review.openstack.org/555456
Committed: https://git.openstack.org/cgit/openstack/python-tripleoclient/commit/?id=11a4adb0abf4249c18dbd4db19a040de9e9f66be
Submitter: Zuul
Branch: master

commit 11a4adb0abf4249c18dbd4db19a040de9e9f66be
Author: Jill Rouleau <email address hidden>
Date: Wed Mar 21 15:17:16 2018 -0700

    Add missing unit tests for undercloud_deploy

    Change-Id: I6fd8291fb5fec590ec0e96f33ac00d553b2fac16
    Closes-Bug: 1757230

Changed in tripleo:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/python-tripleoclient 10.0.0

This issue was fixed in the openstack/python-tripleoclient 10.0.0 release.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.