From c5dfe52ced4f9180933188a9460fead36f92f653 Mon Sep 17 00:00:00 2001 From: zhongjun Date: Tue, 26 Sep 2017 15:35:34 +0800 Subject: Add more test cases in test_deploy.py Add more test cases in test_deploy.py and test_environment.py Change-Id: I6adf3f51aa7a436387c2da8a8dc8c67f6e5a70db Signed-off-by: zhongjun --- tests/data/lab_conf/deploy_bare_odl-ha.yml | 43 ++++++++++++++++++++++ .../lab_conf/deploy_baremetal_invalid_ipmi.yml | 29 +++++++++++++++ tests/data/lab_conf/deploy_vir1_nosdn-ha.yml | 32 ++++++++++++++++ .../lab_conf/deploy_virtual_invalid_template.yml | 31 ++++++++++++++++ 4 files changed, 135 insertions(+) create mode 100644 tests/data/lab_conf/deploy_bare_odl-ha.yml create mode 100644 tests/data/lab_conf/deploy_baremetal_invalid_ipmi.yml create mode 100644 tests/data/lab_conf/deploy_vir1_nosdn-ha.yml create mode 100644 tests/data/lab_conf/deploy_virtual_invalid_template.yml (limited to 'tests/data/lab_conf') diff --git a/tests/data/lab_conf/deploy_bare_odl-ha.yml b/tests/data/lab_conf/deploy_bare_odl-ha.yml new file mode 100644 index 00000000..28e8c195 --- /dev/null +++ b/tests/data/lab_conf/deploy_bare_odl-ha.yml @@ -0,0 +1,43 @@ +adapter: 'ipmi' +hosts: +- name: 'controller01' + roles: + - 'CONTROLLER_LB' + ipmi_ip: '192.168.1.11' + ipmi_user: 'testuser' + ipmi_pass: 'testpass' +- name: 'controller02' + roles: + - 'CONTROLLER_LB' + ipmi_ip: '192.168.1.12' + ipmi_user: 'testuser' + ipmi_pass: 'testpass' +- name: 'controller03' + roles: + - 'CONTROLLER_LB' + ipmi_ip: '192.168.1.13' + ipmi_user: 'testuser' + ipmi_pass: 'testpass' +- name: 'computer01' + roles: + - 'COMPUTER' + ipmi_ip: '192.168.1.14' + ipmi_user: 'testuser' + ipmi_pass: 'testpass' +- name: 'computer02' + roles: + - 'COMPUTER' + ipmi_ip: '192.168.1.15' + ipmi_user: 'testuser' + ipmi_pass: 'testpass' +disks: + daisy: 50 +daisy_passwd: 'r00tme' +daisy_ip: '10.20.0.2' +daisy_gateway: '10.20.0.1' +ceph_disk_name: '/dev/sdb' +modules: + - module: opendaylight + module-config: + - enable_l3_odl: + value: true diff --git a/tests/data/lab_conf/deploy_baremetal_invalid_ipmi.yml b/tests/data/lab_conf/deploy_baremetal_invalid_ipmi.yml new file mode 100644 index 00000000..2e6de5a3 --- /dev/null +++ b/tests/data/lab_conf/deploy_baremetal_invalid_ipmi.yml @@ -0,0 +1,29 @@ +adapter: 'ipmi' +hosts: +- name: 'controller01' + roles: + - 'CONTROLLER_LB' +- name: 'controller02' + roles: + - 'CONTROLLER_LB' +- name: 'controller03' + roles: + - 'CONTROLLER_LB' +- name: 'computer01' + roles: + - 'COMPUTER' + ipmi_ip: '192.168.1.14' + ipmi_user: 'testuser' + ipmi_pass: 'testpass' +- name: 'computer02' + roles: + - 'COMPUTER' + ipmi_ip: '192.168.1.15' + ipmi_user: 'testuser' + ipmi_pass: 'testpass' +disks: + daisy: 50 +daisy_passwd: 'r00tme' +daisy_ip: '10.20.0.2' +daisy_gateway: '10.20.0.1' +ceph_disk_name: '/dev/sdb' \ No newline at end of file diff --git a/tests/data/lab_conf/deploy_vir1_nosdn-ha.yml b/tests/data/lab_conf/deploy_vir1_nosdn-ha.yml new file mode 100644 index 00000000..688b4f4f --- /dev/null +++ b/tests/data/lab_conf/deploy_vir1_nosdn-ha.yml @@ -0,0 +1,32 @@ +adapter: libvirt +hosts: +- name: 'controller01' + roles: + - 'CONTROLLER_LB' + template: 'templates/virtual_environment/vms/controller.xml' +- name: 'controller02' + roles: + - 'CONTROLLER_LB' + template: 'templates/virtual_environment/vms/controller.xml' +- name: 'controller03' + roles: + - 'CONTROLLER_LB' + template: 'templates/virtual_environment/vms/controller.xml' +- name: 'computer01' + roles: + - 'COMPUTER' + template: 'templates/virtual_environment/vms/computer.xml' +- name: 'computer02' + roles: + - 'COMPUTER' + template: 'templates/virtual_environment/vms/computer.xml' +disks: + daisy: 50 + controller: 110 + compute: 110 + ceph: 110 +daisy_passwd: 'r00tme' +daisy_ip: '10.20.11.2' +daisy_gateway: '10.20.11.1' +ceph_disk_name: '/dev/sdb' +modules: diff --git a/tests/data/lab_conf/deploy_virtual_invalid_template.yml b/tests/data/lab_conf/deploy_virtual_invalid_template.yml new file mode 100644 index 00000000..483532cb --- /dev/null +++ b/tests/data/lab_conf/deploy_virtual_invalid_template.yml @@ -0,0 +1,31 @@ +adapter: libvirt +hosts: +- name: 'controller01' + roles: + - 'CONTROLLER_LB' + template: 'controller.xml' +- name: 'controller02' + roles: + - 'CONTROLLER_LB' + template: 'controller.xml' +- name: 'controller03' + roles: + - 'CONTROLLER_LB' + template: 'controller.xml' +- name: 'computer01' + roles: + - 'COMPUTER' + template: 'computer.xml' +- name: 'computer02' + roles: + - 'COMPUTER' + template: 'computer.xml' +disks: + daisy: 50 + controller: 110 + compute: 110 + ceph: 110 +daisy_passwd: 'r00tme' +daisy_ip: '10.20.11.2' +daisy_gateway: '10.20.11.1' +ceph_disk_name: '/dev/sdb' \ No newline at end of file -- cgit 1.2.3-korg