def test_valid_inference_request_for_matching_modality(self):
        """Test creating a valid InferenceRequest with all required fields."""
        for modality, preprocessing_config in [
            (Modality.TEXT, TextPreprocessingConfig()),
            (Modality.AUDIO, AudioPreprocessingConfig()),
            (Modality.VIDEO, VideoPreprocessingConfig()),
            (Modality.IMAGE, ImagePreprocessingConfig()),
        ]:
            with self.subTest(modality=modality, preprocessing_config=preprocessing_config):
                request = InferenceRequest(
                    modality=modality,
                    contents=["some content"],
                    model_config=self.model_config,
                    preprocessing_config=preprocessing_config
                )
                self.assertEqual(request.modality, modality)
                self.assertEqual(request.preprocessing_config, preprocessing_config)
Test creating a valid InferenceRequest with all required fields.
tests/unit_tests/marqo/core/inference/api/test_inference_model_classes.py