-
Notifications
You must be signed in to change notification settings - Fork 3.3k
Change flag workspace-resource-id to workspace-resource #11241
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
Merged
Merged
Changes from all commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
d98929b
[openshift]Change "--workspace-resource-id" to "workspace-resource"
troy0820 dd74388
[openshift]Change HISTORY to reflect change in parameter in az opensh…
troy0820 74d8fbe
[openshift]Change paramter to workspace-id
troy0820 2970cbe
[openshift]Change workspace_resource_id to workspace_id
troy0820 91d7c20
[openshift]Add workspace_id to test for monitorProfile in az openshif…
troy0820 d444557
refine History
25b8edb
remove history and add it in another PR to solve conflicts
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -18,7 +18,7 @@ | |
|
|
||
|
|
||
| class AzureOpenShiftServiceScenarioTest(ScenarioTest): | ||
|
|
||
| # It works in --live mode but fails in replay mode.get rid off @live_only attribute once this resolved | ||
| @live_only() | ||
| @ResourceGroupPreparer(random_name_length=17, name_prefix='clitestosa', location='eastus') | ||
|
|
@@ -67,7 +67,7 @@ def test_openshift_create_default_service(self, resource_group, resource_group_l | |
|
|
||
| # delete | ||
| self.cmd('openshift delete -g {resource_group} -n {name} --yes --no-wait', checks=[self.is_empty()]) | ||
|
|
||
| # It works in --live mode but fails in replay mode.get rid off @live_only attribute once this resolved | ||
| @live_only() | ||
| @ResourceGroupPreparer(random_name_length=17, name_prefix='clitestosa', location='eastus') | ||
|
|
@@ -108,7 +108,7 @@ def test_openshift_create_service_no_wait(self, resource_group, resource_group_l | |
|
|
||
| # show again and expect failure | ||
| self.cmd('openshift show -g {resource_group} -n {name}', expect_failure=True) | ||
|
|
||
| # It works in --live mode but fails in replay mode.get rid off @live_only attribute once this resolved | ||
| @live_only() | ||
| @ResourceGroupPreparer(random_name_length=17, name_prefix='clitestosa', location='eastus') | ||
|
|
@@ -153,3 +153,39 @@ def test_openshift_create_default_service_no_aad(self, resource_group, resource_ | |
|
|
||
| # delete | ||
| self.cmd('openshift delete -g {resource_group} -n {name} --yes --no-wait', checks=[self.is_empty()]) | ||
| # It works in --live mode but fails in replay mode.get rid off @live_only attribute once this resolved | ||
| @live_only() | ||
| @ResourceGroupPreparer(random_name_length=17, name_prefix='clitestosa', location='eastus') | ||
| @ManagedApplicationPreparer() | ||
| def test_openshift_create_with_monitoring(self, resource_group, resource_group_location, aad_client_app_id, aad_client_app_secret): | ||
| # kwargs for string formatting | ||
| osa_name = self.create_random_name('clitestosa', 15) | ||
| self.kwargs.update({ | ||
| 'resource_group': resource_group, | ||
| 'name': osa_name, | ||
| 'location': resource_group_location, | ||
| 'aad_client_app_id': aad_client_app_id, | ||
| 'aad_client_app_secret': aad_client_app_secret | ||
| }) | ||
| workspace = self.cmd("monitor log-analytics workspace create -g {resource_group} -n {osa_name}").get_output_in_json() | ||
| workspace_id = workspace["id"] | ||
| # create | ||
| create_cmd = 'openshift create --resource-group={resource_group} --name={name} --location={location} ' \ | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. is it able to link a workspace since this PR is related with |
||
| '--compute-count=1 ' \ | ||
| '--aad-client-app-id {aad_client_app_id} --aad-client-app-secret {aad_client_app_secret}' \ | ||
| '--workspace-id {workspace_id}' | ||
|
|
||
| self.cmd(create_cmd, checks=[ | ||
| self.exists('fqdn'), | ||
| self.check('provisioningState', 'Succeeded'), | ||
| self.exists('monitorProfile') | ||
| ]) | ||
| # show | ||
| self.cmd('openshift show -g {resource_group} -n {name}', checks=[ | ||
| self.check('name', '{name}'), | ||
| self.check('resourceGroup', '{resource_group}'), | ||
| self.exists('openShiftVersion') | ||
| ]) | ||
| # delete | ||
| self.cmd('openshift delete -g {resource_group} -n {name} --yes --no-wait', checks=[self.is_empty()]) | ||
|
|
||
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
workspace_id=workspace_idinstead ofworkspace_resource_id=workspace_id?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.
If the string passed in to
--workspace-idis, in fact, jus the name of the workspace-id, the variable will still be workspace-id and reference the string to build the workspace-resource-id (/subscriptions/...).