Skip to content

Commit c370598

Browse files
committed
Fix the failed unit tests
1 parent e096a1f commit c370598

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

tests/unit/test_sagemaker_steps.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -160,17 +160,18 @@ def tensorflow_estimator():
160160

161161
@pytest.fixture
162162
def sklearn_processor():
163+
sagemaker_session = MagicMock()
164+
sagemaker_session.boto_region_name = 'us-east-1'
165+
sagemaker_session._default_bucket = 'sagemaker'
166+
163167
processor = SKLearnProcessor(
164168
framework_version="0.20.0",
165169
role=EXECUTION_ROLE,
166170
instance_type="ml.m5.xlarge",
167171
instance_count=1,
172+
sagemaker_session=sagemaker_session
168173
)
169174

170-
processor.sagemaker_session = MagicMock()
171-
processor.sagemaker_session.boto_region_name = 'us-east-1'
172-
processor.sagemaker_session._default_bucket = 'sagemaker'
173-
174175
return processor
175176

176177
@patch('botocore.client.BaseClient._make_api_call', new=mock_boto_api_call)

0 commit comments

Comments
 (0)