code: def test_create_dir_structure_invalid_path(self, mock_path):
      mock_model_path = Mock()
      mock_model_path.exists.return_value = True
      mock_model_path.is_dir.return_value = False
      mock_path.return_value = mock_model_path
  
      with self.assertRaises(ValueError) as context:
          _create_dir_structure(mock_model_path)
  
      self.assertEquals(
          "model_dir is not a valid directory", str(context.exception)
      )
  
file_path: sagemaker-python-sdk/tests/unit/sagemaker/serve/model_server/tgi/test_tgi_prepare.py
imports: from __future__ import absolute_import
  from unittest import TestCase
  from unittest.mock import Mock, PropertyMock, patch
  from sagemaker.serve.model_server.tgi.prepare import _create_dir_structure, _copy_jumpstart_artifacts, _extract_js_resource
  from tests.unit.sagemaker.serve.model_server.constants import MOCK_JUMPSTART_ID, MOCK_TMP_DIR, MOCK_COMPRESSED_MODEL_DATA_STR, MOCK_UNCOMPRESSED_MODEL_DATA_STR, MOCK_UNCOMPRESSED_MODEL_DATA_STR_FOR_DICT, MOCK_UNCOMPRESSED_MODEL_DATA_DICT, MOCK_INVALID_MODEL_DATA_DICT
label_desc: Use image node_id 2 for calling the TgiPrepareTests obj's underlying member method code with example usage: obj.test_create_dir_structure_invalid_path(mock_path) without return types