code: def test_generate_too_many_encoder_kwargs(self):
      model_cls = self.framework_dependent_parameters[
          "AutoModelForSeq2SeqLM"
      ]
      return_tensors = self.framework_dependent_parameters[
          "return_tensors"
      ]
  
      article = """I need input_ids to generate"""
      tokenizer = AutoTokenizer.from_pretrained(
          "hf-internal-testing/tiny-random-bart"
      )
      model = model_cls.from_pretrained(
          "hf-internal-testing/tiny-random-bart", max_length=10
      )
      input_ids = tokenizer(
          article, return_tensors=return_tensors
      ).input_ids
      with self.assertRaises(ValueError):
          model.generate(input_ids=input_ids, inputs_embeds=input_ids)
  
imports: import numpy
  from transformers import AutoTokenizer
  from transformers.testing_utils import slow, torch_device
label_desc: Use image node_id 17 for calling the GenerationIntegrationTestsMixin obj's underlying member method code with example usage: obj.test_generate_too_many_encoder_kwargs() without return types