def test_missing_chunk_config_when_should_chunk(self):
        """Test that a ValueError is raised when should_chunk is True but chunk_config is None."""
        with self.assertRaises(ValueError) as context:
            TextPreprocessingConfig(should_chunk=True)
        self.assertIn("`chunk_config` must be provided when `should_chunk` is True.", str(context.exception))
Test that a ValueError is raised when should_chunk is True but chunk_config is None.
tests/unit_tests/marqo/core/inference/api/test_preprocessing_config.py