openqa/dispatcher: don't check out tests when locally modified

Also don't check out the tests if we're on master branch, but
have local modifications.

Signed-off-by: Adam Williamson <awilliam@redhat.com>
This commit is contained in:
Adam Williamson 2017-09-07 09:56:23 -07:00
parent 873c55d3fc
commit ba788afe08

View file

@ -119,7 +119,7 @@
register: gittests
become: true
become_user: geekotest
when: "(testsbranch.stderr.find('Not a git repository') != -1) or (testsbranch.stdout.find('On branch master') != -1)"
when: "(testsbranch.stderr.find('Not a git repository') != -1) or (testsbranch.stdout.find('On branch master') != -1 and testsbranch.stdout.find('Changes not staged') = -1)"
- name: Remove old openqa_fedora_tools checkout
file: path=/root/openqa_fedora_tools state=absent