Migrate more Azure integration tests. (#29034)
This commit is contained in:
parent
8f4c8844c4
commit
08bdb6198e
10 changed files with 34 additions and 8 deletions
|
@ -110,7 +110,7 @@ except:
|
||||||
from ansible.module_utils.azure_rm_common import AzureRMModuleBase
|
from ansible.module_utils.azure_rm_common import AzureRMModuleBase
|
||||||
|
|
||||||
|
|
||||||
AZURE_ENUM_MODULES = ['azure.mgmt.compute.models.compute_management_client_enums']
|
AZURE_ENUM_MODULES = ['azure.mgmt.compute.models']
|
||||||
|
|
||||||
|
|
||||||
class AzureRMVirtualMachineImageFacts(AzureRMModuleBase):
|
class AzureRMVirtualMachineImageFacts(AzureRMModuleBase):
|
||||||
|
|
3
test/integration/targets/azure_rm_deployment/aliases
Normal file
3
test/integration/targets/azure_rm_deployment/aliases
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
cloud/azure
|
||||||
|
posix/ci/cloud/group2/azure
|
||||||
|
destructive
|
|
@ -0,0 +1,2 @@
|
||||||
|
dependencies:
|
||||||
|
- setup_azure
|
|
@ -1,16 +1,22 @@
|
||||||
|
- name: Create random dns label
|
||||||
|
set_fact:
|
||||||
|
dns_label: "test{{ resource_group | hash('md5') | truncate(16, True, '') + (65535 | random | string) }}"
|
||||||
|
|
||||||
- name: Create Azure Deploy
|
- name: Create Azure Deploy
|
||||||
azure_rm_deployment:
|
azure_rm_deployment:
|
||||||
resource_group: Test_Deployment
|
resource_group: "{{ resource_group }}"
|
||||||
|
location: "eastus"
|
||||||
template_link: 'https://raw.githubusercontent.com/Azure/azure-quickstart-templates/master/101-vm-simple-linux/azuredeploy.json'
|
template_link: 'https://raw.githubusercontent.com/Azure/azure-quickstart-templates/master/101-vm-simple-linux/azuredeploy.json'
|
||||||
|
deployment_name: "{{ dns_label }}"
|
||||||
parameters:
|
parameters:
|
||||||
adminUsername:
|
adminUsername:
|
||||||
value: chouseknecht
|
value: chouseknecht
|
||||||
adminPassword:
|
adminPassword:
|
||||||
value: password123!
|
value: password123!
|
||||||
dnsLabelPrefix:
|
dnsLabelPrefix:
|
||||||
value: testvm9910001
|
value: "{{ dns_label }}"
|
||||||
ubuntuOSVersion:
|
ubuntuOSVersion:
|
||||||
value: "14.04.2-LTS"
|
value: "16.04.0-LTS"
|
||||||
register: output
|
register: output
|
||||||
|
|
||||||
- name: Add new instance to host group
|
- name: Add new instance to host group
|
4
test/integration/targets/azure_rm_securitygroup/aliases
Normal file
4
test/integration/targets/azure_rm_securitygroup/aliases
Normal file
|
@ -0,0 +1,4 @@
|
||||||
|
cloud/azure
|
||||||
|
posix/ci/cloud/group2/azure
|
||||||
|
destructive
|
||||||
|
azure_rm_securitygroup_facts
|
|
@ -0,0 +1,2 @@
|
||||||
|
dependencies:
|
||||||
|
- setup_azure
|
|
@ -0,0 +1,3 @@
|
||||||
|
cloud/azure
|
||||||
|
posix/ci/cloud/group2/azure
|
||||||
|
destructive
|
|
@ -0,0 +1,2 @@
|
||||||
|
dependencies:
|
||||||
|
- setup_azure
|
|
@ -1,10 +1,14 @@
|
||||||
|
- name: set location
|
||||||
|
set_fact:
|
||||||
|
location: eastus
|
||||||
|
|
||||||
- name: Get facts for a specific image
|
- name: Get facts for a specific image
|
||||||
azure_rm_virtualmachineimage_facts:
|
azure_rm_virtualmachineimage_facts:
|
||||||
location: "{{ location }}"
|
location: "{{ location }}"
|
||||||
publisher: OpenLogic
|
publisher: OpenLogic
|
||||||
offer: CentOS
|
offer: CentOS
|
||||||
sku: '7.1'
|
sku: '7.3'
|
||||||
version: '7.1.20150731'
|
version: '7.3.20170707'
|
||||||
register: output
|
register: output
|
||||||
|
|
||||||
- assert:
|
- assert:
|
||||||
|
@ -15,7 +19,7 @@
|
||||||
location: "{{ location }}"
|
location: "{{ location }}"
|
||||||
publisher: OpenLogic
|
publisher: OpenLogic
|
||||||
offer: CentOS
|
offer: CentOS
|
||||||
sku: '7.1'
|
sku: '7.3'
|
||||||
register: output
|
register: output
|
||||||
|
|
||||||
- assert:
|
- assert:
|
Loading…
Reference in a new issue