Skip to content
Merged
Show file tree
Hide file tree
Changes from all 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
2 changes: 1 addition & 1 deletion src/azure-cli/azure/cli/command_modules/vm/custom.py
Original file line number Diff line number Diff line change
Expand Up @@ -3230,7 +3230,7 @@ def create_gallery_image(cmd, resource_group_name, gallery_name, gallery_image_n
os_type=os_type, os_state=os_state, end_of_life_date=end_of_life_date,
recommended=recommendation, disallowed=Disallowed(disk_types=disallowed_disk_types),
purchase_plan=purchase_plan, location=location, eula=eula, tags=(tags or {}),
hyper_vgeneration=hyper_v_generation, features=feature_list)
hyper_v_generation=hyper_v_generation, features=feature_list)
Copy link
Member

Choose a reason for hiding this comment

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

is this due to track2?

Copy link
Member Author

Choose a reason for hiding this comment

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

Yes, it is.

return client.gallery_images.begin_create_or_update(resource_group_name, gallery_name, gallery_image_name, image)


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -770,9 +770,9 @@ def test_vm_disk_max_shares_etc(self, resource_group):
self.cmd('sig create -g {rg} --gallery-name {g1}')
self.cmd('sig image-definition create -g {rg} --gallery-name {g1} --gallery-image-definition image --os-type linux -p publisher1 -f offer1 -s sku1 --features "IsSecureBootSupported=false IsMeasuredBootSupported=false" --hyper-v-generation V2', checks=[
self.check('features[0].name', 'IsSecureBootSupported'),
self.check('features[0].value', 'false'),
self.check('features[0].value', 'false', False),
Copy link
Member

Choose a reason for hiding this comment

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

why the change

Copy link
Member Author

Choose a reason for hiding this comment

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

Service change. It returns "False" not "false"

Copy link
Member

Choose a reason for hiding this comment

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

can the test util be changed to support case-insensitive compare?

Copy link
Member Author

Choose a reason for hiding this comment

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

The "False" I added means case sensitive = False. Default value is True.

self.check('features[1].name', 'IsMeasuredBootSupported'),
self.check('features[1].value', 'false'),
self.check('features[1].value', 'false', False),
])
self.cmd('disk create -g {rg} -n disk --size-gb 10')
self.cmd('snapshot create -g {rg} -n s1 --source disk')
Expand Down Expand Up @@ -4659,14 +4659,14 @@ def test_disk_access(self, resource_group):
self.cmd('disk create -g {rg} -n {disk} --size-gb 10 --network-access-policy AllowPrivate --disk-access {diskaccess}')
self.cmd('disk show -g {rg} -n {disk}', checks=[
self.check('name', '{disk}'),
self.check('diskAccessId', disk_access_id),
self.check('diskAccessId', disk_access_id, False),
self.check('networkAccessPolicy', 'AllowPrivate')
])

self.cmd('snapshot create -g {rg} -n {snapshot} --size-gb 10 --network-access-policy AllowPrivate --disk-access {diskaccess}')
self.cmd('snapshot show -g {rg} -n {snapshot}', checks=[
self.check('name', '{snapshot}'),
self.check('diskAccessId', disk_access_id),
self.check('diskAccessId', disk_access_id, False),
self.check('networkAccessPolicy', 'AllowPrivate')
])

Expand Down