code: def test_overrides(self, input_type):
      filename = (
          self.FIXTURES_ROOT / "simple_tagger" / "experiment.json"
      )
      overrides = {
          "train_data_path": "FOO",
          "model.type": "BAR",
          "model.text_field_embedder.token_embedders.tokens.type": "BAZ",
          "data_loader.batch_sampler.sorting_keys.0": "question",
      }
      params = Params.from_file(
          filename,
          overrides if input_type == dict else json.dumps(overrides),
      )
  
      assert "dataset_reader" in params
      assert "trainer" in params
      assert params["train_data_path"] == "FOO"
      assert (
          params["data_loader"]["batch_sampler"]["sorting_keys"][0]
          == "question"
      )
  
      model_params = params.pop("model")
      assert model_params.pop("type") == "BAR"
      assert (
          model_params["text_field_embedder"]["token_embedders"][
              "tokens"
          ]["type"]
          == "BAZ"
      )
  
imports: import json
  import os
  import re
  from collections import OrderedDict
  import pytest
  from allennlp.common.checks import ConfigurationError
  from allennlp.common.params import infer_and_cast, Params, remove_keys_from_params, with_overrides
  from allennlp.common.testing import AllenNlpTestCase
label_desc: Use image node_id 6 for calling the TestParams obj's underlying member method code with example usage: obj.test_overrides(input_type) without return types