File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -25,8 +25,8 @@ def test_local_training():
2525 f"""
2626 Compare with https://github.com/aws/amazon-sagemaker-examples/tree/main/advanced_functionality/scikit_bring_your_own/container/local_test .
2727 """
28- assert training_environment .SAGEMAKER_BASE_PATH == "/opt/ml"
29- assert training_environment .base_dir .endswith ("/opt_ml" )
28+ assert training_environment .SAGEMAKER_BASE_PATH == "/opt/ml" , "default path should be /opt/ml"
29+ assert training_environment .base_dir .endswith ("/opt_ml" ), "override path should end with /opt_ml"
3030
3131 test_util ._clean_training_opt_ml_dir ()
3232 distutils .dir_util .copy_tree ("./source_dir/training_clean/" , "./opt_ml/code/" )
@@ -44,7 +44,7 @@ def test_local_training():
4444 logging .info ("Finished training" )
4545
4646
47- @mock .patch .dict (os .environ , {"SM_MODEL_DIR" : "./ opt_ml/model" })
47+ @mock .patch .dict (os .environ , {"SM_MODEL_DIR" : os . path . join ( os . path . dirname ( __file__ ), " opt_ml/model") })
4848def test_local_training_with_coverage ():
4949 # import will start training
5050 from source_dir .training_clean import train_clean
You can’t perform that action at this time.
0 commit comments