def test_loading_languagebind_model_from_a_zip_on_s3_with_role(self):
        """A test for loading a LanguagebindModel from a zip file on S3 using a role."""
        model_properties = {
            "dimensions": 768,
            "type": "languagebind",
            "supportedModalities": ["text", "image", "audio", "video"],
            "modelLocation": {
                "image": {"s3": {"Bucket": "opensource-languagebind-models", "Key": "LanguageBind_Image.zip"}},
                "audio": {"s3": {"Bucket": "opensource-languagebind-models", "Key": "LanguageBind_Audio_FT.zip"}},
                "video": {"s3": {"Bucket": "opensource-languagebind-models", "Key": "LanguageBind_Video_V1.5_FT.zip"}},
            }
        }

        model = LanguagebindModel(
            device="cuda", model_properties=model_properties
        )
        raised_exception = RuntimeError("Stop here")
        with (patch("marqo.inference.model_download.model_download.get_presigned_s3_url",side_effect=raised_exception)
              as mock_presigned_url):
            with patch("marqo.inference.model_download.model_download.check_s3_model_already_exists", return_value=False):
                with self.assertRaises(RuntimeError) as context:
                    model.load()

        # Ensure that the get_presigned_s3_url function was called thus role based access was attempted
        mock_presigned_url.assert_called_once()
A test for loading a LanguagebindModel from a zip file on S3 using a role.
tests/integ_tests/inference/native_inference/embedding_models/test_languagebind_model_load.py