class_docstr: Basic tests on the built-in parlai Dictionary.
class_docstr_tok: ["Basic","tests","on","the","built-in","parlai","Dictionary","."]
docstr: Ensure training a model requires a dict_file or model_file.
code: def test_train_model_with_no_dict_file(self):
      """
      Ensure training a model requires a dict_file or model_file.
      """
      import parlai.scripts.train_model as tms
  
      parser = tms.setup_args()
      parser.set_params(task="babi:task1k:1", model="seq2seq")
      popt = parser.parse_args([])
      with self.assertRaises(RuntimeError):
          tms.TrainLoop(popt)
  
imports: from parlai.core.build_data import modelzoo_path
  from parlai.core.dict import find_ngrams
  from parlai.core.params import ParlaiParser
  from parlai.core.dict import DictionaryAgent, TokenizationMode
  from parlai.core.opt import Opt
  import parlai.scripts.build_dict
  from parlai.utils.io import PathManager
  import parlai.utils.testing
  import os
  import shutil
  import unittest
  import pytest
label_desc: Use image node_id 7 for calling the TestDictionary obj's underlying member method code with example usage: obj.test_train_model_with_no_dict_file() without return types