-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
{Azurestack} ACR & AKS: Adding Tests and Fixing Authorization api-version for hybrid profile #18443
Conversation
Azurestack |
please make CI pass first |
@Juliehzl - All CI checks passed. Please review |
@@ -241,7 +241,7 @@ def default_api_version(self): | |||
ResourceType.MGMT_RESOURCE_SUBSCRIPTIONS: '2016-06-01', | |||
ResourceType.MGMT_RESOURCE_TEMPLATESPECS: '2015-01-01', | |||
ResourceType.MGMT_NETWORK_DNS: '2016-04-01', | |||
ResourceType.MGMT_AUTHORIZATION: SDKProfile('2016-09-01', { | |||
ResourceType.MGMT_AUTHORIZATION: SDKProfile('2015-07-01', { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there a downgrade for authorization?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is not a downgrade, This is a bug fix. In our earlier PR we have mistakenly updated the api version @Juliehzl
from ._errors import CMK_MANAGED_IDENTITY_ERROR | ||
_handle_error(CMK_MANAGED_IDENTITY_ERROR.format_error_message(registry_name), ignore_errors) | ||
if cmd.supported_api_version(min_api='2020-11-01-preview', resource_type=ResourceType.MGMT_CONTAINERREGISTRY): # pylint: disable=too-many-nested-blocks | ||
# CMK settings |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please also add acr code owner to review your change
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Bhuvaneswari-Santharam I tested this locally and it looks good. @northtyphoon we should consider adding some unit tests for acr check-health
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approved for ACR.
@Bhuvaneswari-Santharam I tested this locally and it looks good.
@northtyphoon we should consider adding some unit tests for acr check-health
@northtyphoon please add more unit tests as @adewaleo mentioned. |
@yonzhan, I was making this suggestion as a follow up item. Given |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Need to update some recording files, since some of the tests failed.
.../command_modules/acs/tests/hybrid_2020_09_01/recordings/test_aks_availability_zones_msi.yaml
Outdated
Show resolved
Hide resolved
...cs/tests/hybrid_2020_09_01/recordings/test_aks_create_aadv1_and_update_with_managed_aad.yaml
Outdated
Show resolved
Hide resolved
...ests/hybrid_2020_09_01/recordings/test_aks_create_aadv1_and_update_with_managed_aad_msi.yaml
Outdated
Show resolved
Hide resolved
...ure/cli/command_modules/acs/tests/hybrid_2020_09_01/recordings/test_aks_create_blb_vmas.yaml
Outdated
Show resolved
Hide resolved
...cli/command_modules/acs/tests/hybrid_2020_09_01/recordings/test_aks_create_blb_vmas_msi.yaml
Outdated
Show resolved
Hide resolved
...2020_09_01/recordings/test_aks_create_slb_vmss_with_default_mgd_outbound_ip_then_update.yaml
Outdated
Show resolved
Hide resolved
...i/command_modules/acs/tests/hybrid_2020_09_01/recordings/test_aks_create_fqdn_subdomain.yaml
Outdated
Show resolved
Hide resolved
...nd_modules/acs/tests/hybrid_2020_09_01/recordings/test_openshift_create_default_service.yaml
Outdated
Show resolved
Hide resolved
...les/acs/tests/hybrid_2020_09_01/recordings/test_openshift_create_default_service_no_aad.yaml
Outdated
Show resolved
Hide resolved
...nd_modules/acs/tests/hybrid_2020_09_01/recordings/test_openshift_create_service_no_wait.yaml
Outdated
Show resolved
Hide resolved
|
||
# pylint: skip-file | ||
import unittest | ||
import mock |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
mock
module is deprecated in azure cli. see #19024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
AKS test recordings looks good to me.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
mock
module is deprecated in azure cli. see #19024
from urllib import urlencode | ||
import json | ||
import unittest | ||
import mock |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
still have mock here.
Description
Testing Guide
This checklist is used to make sure that common guidelines for a pull request are followed.
The PR title and description has followed the guideline in Submitting Pull Requests.
I adhere to the Command Guidelines.
I adhere to the Error Handling Guidelines.