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
15 changes: 6 additions & 9 deletions scripts/ci/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -62,10 +62,8 @@ fi
# build test packages
title 'Build Azure CLI tests package'

for test_src in $(find src/command_modules -name tests -type d); do
rel_path=${test_src##src/command_modules/}
rel_path=(${rel_path/\// })
rel_path=${rel_path[1]}
for test_src in $(find src/azure-cli/azure/cli/command_modules -name tests -type d); do
rel_path=${test_src##src/azure-cli/}

mkdir -p $testsrc_dir/$rel_path
cp -R $test_src/* $testsrc_dir/$rel_path
Expand Down Expand Up @@ -125,13 +123,12 @@ if [ "$target_profile" == "latest" ]; then
echo " 'azure.cli.core.tests'," >>$testsrc_dir/setup.py
fi

for name in `ls src/command_modules | grep azure-cli-`; do
module_name=${name##azure-cli-}
test_folder=src/command_modules/$name/azure/cli/command_modules/$module_name/tests
for name in `ls src/azure-cli/azure/cli/command_modules`; do
test_folder=src/azure-cli/azure/cli/command_modules/$name/tests
if [ -d $test_folder ]; then
echo " 'azure.cli.command_modules.$module_name.tests'," >>$testsrc_dir/setup.py
echo " 'azure.cli.command_modules.$name.tests'," >>$testsrc_dir/setup.py
if [ -d $test_folder/$target_profile ]; then
echo " 'azure.cli.command_modules.$module_name.tests.$target_profile'," >>$testsrc_dir/setup.py
echo " 'azure.cli.command_modules.$name.tests.$target_profile'," >>$testsrc_dir/setup.py
fi
fi
done
Expand Down

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@

class AzureKubernetesServiceScenarioTest(ScenarioTest):

# Remove when issue #9392 is addressed.
# TODO: Remove when issue #9392 is addressed.
@live_only()
@AllowLargeResponse()
@ResourceGroupPreparer(random_name_length=17, name_prefix='clitest', location='eastus')
Expand Down Expand Up @@ -110,6 +110,7 @@ def test_aks_create_default_service(self, resource_group, resource_group_locatio
# delete
self.cmd('aks delete -g {resource_group} -n {name} --yes --no-wait', checks=[self.is_empty()])

@AllowLargeResponse()
@ResourceGroupPreparer(random_name_length=17, name_prefix='clitest', location='eastus')
@RoleBasedServicePrincipalPreparer()
def test_aks_create_service_no_wait(self, resource_group, resource_group_location, sp_name, sp_password):
Expand Down Expand Up @@ -191,6 +192,8 @@ def test_aks_create_service_no_wait(self, resource_group, resource_group_locatio
# show again and expect failure
self.cmd('aks show -g {resource_group} -n {name}', expect_failure=True)

# TODO: remove when issue #9392 is addressed.
@live_only()
@ResourceGroupPreparer(random_name_length=17, name_prefix='clitest', location='westus2')
@RoleBasedServicePrincipalPreparer()
def test_aks_create_scale_with_custom_nodepool_name(self, resource_group, resource_group_location, sp_name, sp_password):
Expand Down Expand Up @@ -271,7 +274,7 @@ def test_aks_bad_inputs(self, resource_group, resource_group_location, sp_name,
self.cmd(create_cmd)
self.assertIn('--max-pods', str(err.exception))

# Remove when issue #9392 is addressed.
# TODO: Remove when issue #9392 is addressed.
@live_only()
@AllowLargeResponse(8192)
@ResourceGroupPreparer(random_name_length=17, name_prefix='clitest', location='eastus')
Expand Down Expand Up @@ -316,7 +319,7 @@ def test_aks_create_default_service_without_skip_role_assignment(self, resource_
self.check('provisioningState', 'Succeeded')
])

# Remove when issue #9392 is addressed.
# TODO: Remove when issue #9392 is addressed.
@live_only()
@AllowLargeResponse(8192)
@ResourceGroupPreparer(random_name_length=17, name_prefix='clitest', location='eastus')
Expand Down Expand Up @@ -345,7 +348,7 @@ def test_aks_create_default_service_with_skip_role_assignment(self, resource_gro
self.is_empty()
])

# Remove when issue #9392 is addressed.
# TODO: Remove when issue #9392 is addressed.
@live_only()
@AllowLargeResponse(8192)
@ResourceGroupPreparer(random_name_length=17, name_prefix='clitest', location='eastus')
Expand All @@ -370,7 +373,7 @@ def test_aks_create_default_service_without_SP_and_with_role_assignment(self, re
self.check('[0].scope', '{vnet_subnet_id}')
])

# It works in --live mode but fails in replay mode.get rid off @live_only attribute once this resolved
# TODO: Remove when issue #9392 is addressed.
@live_only()
@ResourceGroupPreparer(random_name_length=17, name_prefix='clitest', location='eastus')
@RoleBasedServicePrincipalPreparer()
Expand Down

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -1172,6 +1172,8 @@ def test_functionapp_with_no_default_app_insights(self, resource_group, storage_
functionapp_name)).get_output_in_json()
self.assertTrue('APPINSIGHTS_INSTRUMENTATIONKEY' not in [kp['name'] for kp in app_set])

# TODO: Remove when issue #9769 is resolved.
@live_only()
@ResourceGroupPreparer(location='westcentralus')
@StorageAccountPreparer()
def test_functionapp_unavailable_location_app_insights(self, resource_group, storage_account):
Expand Down
Loading