Skip to content

Commit

Permalink
extension cases: change cases which have the requirement for blob pub…
Browse files Browse the repository at this point in the history
…lic access priority into 5
  • Loading branch information
LiliDeng committed Aug 19, 2024
1 parent 4c18740 commit cfeec66
Show file tree
Hide file tree
Showing 3 changed files with 64 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -102,8 +102,11 @@ def before_case(self, log: Logger, **kwargs: Any) -> None:
@TestCaseMetadata(
description="""
Runs the Custom Script VM extension with a public Azure storage file uri.
Downgrading priority from 1 to 5. Due to the requirement for blob public access,
which is restricted for security reasons.
""",
priority=1,
priority=5,
)
def verify_public_script_run(
self, log: Logger, node: Node, environment: Environment
Expand All @@ -130,8 +133,11 @@ def verify_public_script_run(
description="""
Runs the Custom Script VM extension with 2 public file uris passed in
and second script being run. Verifies second script created.
Downgrading priority from 3 to 5. Due to the requirement for blob public access,
which is restricted for security reasons.
""",
priority=3,
priority=5,
)
def verify_second_public_script_run(
self, log: Logger, node: Node, environment: Environment
Expand Down Expand Up @@ -173,8 +179,11 @@ def verify_second_public_script_run(
description="""
Runs the Custom Script VM extension with public file uri and command
in both public and protected settings.
Downgrading priority from 3 to 5. Due to the requirement for blob public access,
which is restricted for security reasons.
""",
priority=3,
priority=5,
)
def verify_script_in_both_settings_failed(
self, log: Logger, node: Node, environment: Environment
Expand Down Expand Up @@ -208,8 +217,11 @@ def verify_script_in_both_settings_failed(
description="""
Runs the Custom Script VM extension with public file uri and command in
protected settings.
Downgrading priority from 3 to 5. Due to the requirement for blob public access,
which is restricted for security reasons.
""",
priority=3,
priority=5,
)
def verify_public_script_protected_settings_run(
self, log: Logger, node: Node, environment: Environment
Expand Down Expand Up @@ -241,8 +253,11 @@ def verify_public_script_protected_settings_run(
@TestCaseMetadata(
description="""
Runs the Custom Script VM extension without a command and a script.
Downgrading priority from 3 to 5. Due to the requirement for blob public access,
which is restricted for security reasons.
""",
priority=3,
priority=5,
)
def verify_public_script_without_command_run(
self, log: Logger, node: Node, environment: Environment
Expand Down Expand Up @@ -292,8 +307,11 @@ def verify_base64_script_with_command_run(self, log: Logger, node: Node) -> None
@TestCaseMetadata(
description="""
Runs the Custom Script VM extension with a base64 script.
Downgrading priority from 3 to 5. Due to the requirement for blob public access,
which is restricted for security reasons.
""",
priority=3,
priority=5,
)
def verify_public_script_with_base64_script_run(
self, log: Logger, node: Node, environment: Environment
Expand Down Expand Up @@ -322,8 +340,11 @@ def verify_public_script_with_base64_script_run(
@TestCaseMetadata(
description="""
Runs the Custom Script VM extension with a gzip'ed base64 script.
Downgrading priority from 3 to 5. Due to the requirement for blob public access,
which is restricted for security reasons.
""",
priority=3,
priority=5,
)
def verify_public_script_with_gzip_base64_script_run(
self, log: Logger, node: Node, environment: Environment
Expand Down Expand Up @@ -464,8 +485,11 @@ def verify_private_sas_script_run(
description="""
Runs the Custom Script VM extension with a public Azure storage file uri
pointing to a python script.
Downgrading priority from 3 to 5. Due to the requirement for blob public access,
which is restricted for security reasons.
""",
priority=3,
priority=5,
)
def verify_public_python_script_run(
self, log: Logger, node: Node, environment: Environment
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -97,8 +97,11 @@ class RunCommandV1Tests(TestSuite):
@TestCaseMetadata(
description="""
Runs the Run Command v2 VM extension with a public Azure storage file uri.
Downgrading priority from 3 to 5. Due to the requirement for blob public access,
which is restricted for security reasons.
""",
priority=3,
priority=5,
)
def verify_public_script_run(
self, log: Logger, node: Node, environment: Environment
Expand All @@ -125,8 +128,11 @@ def verify_public_script_run(
description="""
Runs the Run Command v1 VM extension with 2 public file uris passed in
and second script being run. Verifies second script created.
Downgrading priority from 3 to 5. Due to the requirement for blob public access,
which is restricted for security reasons.
""",
priority=3,
priority=5,
)
def verify_second_public_script_run(
self, log: Logger, node: Node, environment: Environment
Expand Down Expand Up @@ -168,8 +174,11 @@ def verify_second_public_script_run(
description="""
Runs the Run Command v1 VM extension with public file uri and command
in both public and protected settings.
Downgrading priority from 3 to 5. Due to the requirement for blob public access,
which is restricted for security reasons.
""",
priority=3,
priority=5,
)
def verify_script_in_both_settings_failed(
self, log: Logger, node: Node, environment: Environment
Expand Down Expand Up @@ -203,8 +212,11 @@ def verify_script_in_both_settings_failed(
description="""
Runs the Run Command v1 VM extension with public file uri and command in
protected settings.
Downgrading priority from 3 to 5. Due to the requirement for blob public access,
which is restricted for security reasons.
""",
priority=3,
priority=5,
)
def verify_public_script_protected_settings_run(
self, log: Logger, node: Node, environment: Environment
Expand Down Expand Up @@ -236,8 +248,11 @@ def verify_public_script_protected_settings_run(
@TestCaseMetadata(
description="""
Runs the Run Command v1 VM extension without a command and a script.
Downgrading priority from 3 to 5. Due to the requirement for blob public access,
which is restricted for security reasons.
""",
priority=3,
priority=5,
)
def verify_public_script_without_command_run_failed(
self, log: Logger, node: Node, environment: Environment
Expand Down Expand Up @@ -289,8 +304,11 @@ def verify_base64_script_with_command_run_failed(
@TestCaseMetadata(
description="""
Runs the Custom Script VM extension with a base64 script.
Downgrading priority from 3 to 5. Due to the requirement for blob public access,
which is restricted for security reasons.
""",
priority=3,
priority=5,
)
def verify_public_script_with_base64_script_run(
self, log: Logger, node: Node, environment: Environment
Expand Down Expand Up @@ -460,8 +478,11 @@ def verify_private_sas_script_run(
description="""
Runs the Run Command v1 VM extension with a public Azure storage file uri
pointing to a python script.
Downgrading priority from 3 to 5. Due to the requirement for blob public access,
which is restricted for security reasons.
""",
priority=3,
priority=5,
)
def verify_public_python_script_run(
self, log: Logger, node: Node, environment: Environment
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -207,8 +207,11 @@ def verify_script_run_with_protected_parameter(
description="""
Runs the Run Command v2 VM extension with a public uri pointing to the
script in blob storage.
Downgrading priority from 3 to 5. Due to the requirement for blob public access,
which is restricted for security reasons.
""",
priority=3,
priority=5,
)
def verify_public_uri_script_run(
self, log: Logger, node: Node, environment: Environment
Expand Down

0 comments on commit cfeec66

Please sign in to comment.