def METHOD_NAME(self, mock):
    from torchtext.models import T5Conf, T5Bundle
    # encoder-decoder with generation
    dummy_t5_generation_conf = T5Conf(
        encoder_only=False,
        linear_head=True,
        vocab_size=10,
        embedding_dim=16,
        ffn_dimension=64,
        num_attention_heads=2,
        num_encoder_layers=2,
        num_decoder_layers=2,
    )
    t5_generation_bundle = T5Bundle(dummy_t5_generation_conf)
    t5_generation_bundle.get_model(load_weights=False, freeze_model=True)
    mock.assert_called_with(
        "The model is not loaded with pre-trained weights. Setting freeze_model to True will hinder model from learning appropriate weights."
    )