Skip to content

Commit 1a25531

Browse files
committed
added unit tests for SMM changes
1 parent 61bef3d commit 1a25531

File tree

1 file changed

+0
-20
lines changed

1 file changed

+0
-20
lines changed

tests/unitary/with_extras/aqua/test_deployment.py

Lines changed: 0 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -3053,26 +3053,6 @@ def test_case_3_value_overrides_defaults(self, mock_model_app, mock_deploy):
30533053
# SMM Default should be GONE
30543054
self.assertNotIn("--default-param 100", final_params)
30553055

3056-
@patch("ads.aqua.app.ModelDeployment")
3057-
@patch("ads.aqua.app.AquaModelApp")
3058-
def test_validation_blocks_restricted_params(self, mock_model_app, mock_deploy):
3059-
"""Test that restricted params cause error regardless of input source."""
3060-
3061-
# Setup: Container config has restricted params
3062-
self.mock_container_item.spec.restricted_params = ["--seed"]
3063-
3064-
# User tries to override restricted param
3065-
details = CreateModelDeploymentDetails(
3066-
model_id="ocid1.model...",
3067-
instance_shape="VM.GPU.A10.1",
3068-
env_var={"PARAMS": "--seed 999"},
3069-
)
3070-
3071-
with self.assertRaises(AquaValueError) as context:
3072-
self.app.create(create_deployment_details=details)
3073-
3074-
self.assertIn("Parameters ['--seed'] are set by Aqua", str(context.exception))
3075-
30763056

30773057
class TestMultiModelParamResolution(unittest.TestCase):
30783058
"""Tests strictly for the SMM parameter resolution logic in Multi-Model."""

0 commit comments

Comments
 (0)