blob: 193c4d73e2c580b734ce95e05f9c46ca2d24792a [file] [log] [blame]
Andy Baviera4cf1a72017-10-16 16:10:12 -07001
2# Copyright 2017-present Open Networking Foundation
3#
4# Licensed under the Apache License, Version 2.0 (the "License");
5# you may not use this file except in compliance with the License.
6# You may obtain a copy of the License at
7#
8# http://www.apache.org/licenses/LICENSE-2.0
9#
10# Unless required by applicable law or agreed to in writing, software
11# distributed under the License is distributed on an "AS IS" BASIS,
12# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13# See the License for the specific language governing permissions and
14# limitations under the License.
15
16
17---
18# test-mcord-base/tasks/main.yml
19# Run tests to check that the base elements of M-CORD are present
20
21- name: Wait for networks to be synchronized
22 shell: bash -c "source /opt/cord_profile/admin-openrc.sh; neutron net-list|grep '{{ item }}' > /dev/null"
23 register: result
24 until: result | success
25 retries: 10
26 delay: 60
Andy Bavier50f53172017-10-24 06:02:36 -070027 with_items: "{{ test_networks }}"
Andy Baviera4cf1a72017-10-16 16:10:12 -070028 tags:
29 - skip_ansible_lint # running a sub job
30
31- name: Wait for VMs to come up
32 shell: bash -c "source /opt/cord_profile/admin-openrc.sh; nova list --all-tenants|grep '{{ item }}.*ACTIVE' > /dev/null"
33 register: result
34 until: result | success
35 retries: 10
36 delay: 60
Andy Bavier50f53172017-10-24 06:02:36 -070037 with_items: "{{ test_services }}"
38 tags:
39 - skip_ansible_lint # running a sub job
40
41- name: Verify that VMs are properly networked
42 shell: bash -c "source /opt/cord_profile/admin-openrc.sh; nova list --all-tenants|grep '{{ item.vm }}.*ACTIVE.*{{ item.network }}' > /dev/null"
43 with_items: "{{ test_ports }}"
Andy Baviera4cf1a72017-10-16 16:10:12 -070044 tags:
45 - skip_ansible_lint # running a sub job