Skip to content
Merged
Show file tree
Hide file tree
Changes from 5 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion sdk/compute/azure-mgmt-compute/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,10 @@
pass

# Version extraction inspired from 'requests'
with open(os.path.join(package_folder_path, 'version.py'), 'r') as fd:
# Version extraction inspired from 'requests'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@zikalino duplicated comment

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah, noticed, have to fix update_pr thingy :-(

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

with open(os.path.join(package_folder_path, 'version.py')
if os.path.exists(os.path.join(package_folder_path, 'version.py'))
else os.path.join(package_folder_path, '_version.py'), 'r') as fd:
version = re.search(r'^VERSION\s*=\s*[\'"]([^\'"]*)[\'"]',
fd.read(), re.MULTILINE).group(1)

Expand Down
11 changes: 7 additions & 4 deletions sdk/compute/azure-mgmt-compute/tests/test_cli_mgmt_compute.py
Original file line number Diff line number Diff line change
Expand Up @@ -187,10 +187,13 @@ def test_compute(self, resource_group):
INSTANCE_IDS = ["1"]
LOG_ANALYTIC_NAME = "loganalytic"


SUBNET = self.create_virtual_network(RESOURCE_GROUP, AZURE_LOCATION, NETWORK_NAME, SUBNET_NAME)
NIC_ID = self.create_network_interface(RESOURCE_GROUP, AZURE_LOCATION, INTERFACE_NAME, SUBNET)
# VAULT_ID, VAULT_URL, KEY_NAME = self.create_key(RESOURCE_GROUP, AZURE_LOCATION, KEY_VAULT, TENANT_ID)
if self.is_live:
SUBNET = self.create_virtual_network(RESOURCE_GROUP, AZURE_LOCATION, NETWORK_NAME, SUBNET_NAME)
NIC_ID = self.create_network_interface(RESOURCE_GROUP, AZURE_LOCATION, INTERFACE_NAME, SUBNET)
# VAULT_ID, VAULT_URL, KEY_NAME = self.create_key(RESOURCE_GROUP, AZURE_LOCATION, KEY_VAULT, TENANT_ID)
else:
SUBNET = "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/" + RESOURCE_GROUP + "/providers/Microsoft.Network/virtualNetworks/" + NETWORK_NAME + "/subnets/" + SUBNET_NAME
NIC_ID = "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/" + RESOURCE_GROUP + "/providers/Microsoft.Network/networkInterfaces/" + INTERFACE_NAME

# Create an empty managed disk.[put]
BODY = {
Expand Down
1 change: 1 addition & 0 deletions sdk/compute/azure-mgmt-compute/tests/test_mgmt_compute.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#--------------------------------------------------------------------------

import unittest

from collections import namedtuple
Expand Down