def METHOD_NAME(self):
    self._set_up()
    md_builder = saved_model_metadata_builder.SavedModelMetadataBuilder(
        self.model_path, tags=[tf.saved_model.tag_constants.SERVING]
    )
    generated_md = md_builder.get_metadata_protobuf()
    try:
        models.Model.upload(
            display_name=test_constants.ModelConstants._TEST_MODEL_NAME,
            serving_container_image_uri=test_constants.ModelConstants._TEST_SERVING_CONTAINER_IMAGE,
            explanation_parameters=test_constants.ModelConstants._TEST_EXPLANATION_PARAMETERS,
            explanation_metadata=generated_md,  # Test metadata from builder
            labels=test_constants.ModelConstants._TEST_LABEL,
        )
    except TypeError as e:
        if "Parameter to MergeFrom() must be instance of same class" in str(e):
            pytest.fail(
                f"Model.upload() expects different proto version, more info: {e}"
            )
        else:
            raise e