Skip to content

Commit e740967

Browse files
committed
fix unit test failure
1 parent 98f1422 commit e740967

File tree

2 files changed

+4
-5
lines changed

2 files changed

+4
-5
lines changed

tests/unit/sagemaker/local/test_local_entities.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
# language governing permissions and limitations under the License.
1313
from __future__ import absolute_import
1414

15+
import re
1516
import os
1617
import pytest
1718

@@ -290,10 +291,8 @@ def test_start_local_pipeline_with_wrong_parameter_type(sagemaker_local_session)
290291
local_pipeline = sagemaker.local.entities._LocalPipeline(pipeline)
291292
with pytest.raises(ClientError) as error:
292293
local_pipeline.start(PipelineParameters={"MyStr": True})
293-
assert (
294-
f"Unexpected type for parameter '{parameter.name}'. Expected "
295-
f"{parameter.parameter_type.python_type} but found {type(True)}." in str(error.value)
296-
)
294+
expected_error_pattern = r"Unexpected type for parameter 'MyStr'\. Expected .* but found <class 'bool'>\."
295+
assert re.search(expected_error_pattern, str(error.value))
297296

298297

299298
def test_start_local_pipeline_with_empty_parameter_string_value(

tests/unit/sagemaker/serve/detector/test_dependency_manager.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@
3434

3535
EXPECTED_DEPENDENCY_MAP = {
3636
"requests": "==2.26.0",
37-
"numpy": ">=1.20.0",
37+
"numpy": "==1.26.4",
3838
"pandas": "<=1.3.3",
3939
"matplotlib": "<3.5.0",
4040
"scikit-learn": ">0.24.1",

0 commit comments

Comments
 (0)