code: def test_index_converts_field_correctly(self):
      # pylint: disable=protected-access
      self.field.index(self.vocab)
      assert list(self.field._indexed_entity_texts.keys()) == set(
          ["tokens"]
      )
      # Note that these are sorted by their _identifiers_, not their cell text, so the
      # `fb:row.rows` show up after the `fb:cells`.
      expected_array = [
          [self.negative_one_index],
          [self.zero_index],
          [self.one_index],
          [self.edirne_index],
          [self.lake_index, self.gala_index],
          [self.mersin_index],
          [self.paradeniz_index],
          [self.location_index, self.in_index, self.english_index],
          [self.name_index, self.in_index, self.english_index],
      ]
      assert (
          self.field._indexed_entity_texts["tokens"] == expected_array
      )
  
imports: from __future__ import division
  from __future__ import with_statement
  from __future__ import absolute_import
  from collections import defaultdict
  import pytest
  from numpy.testing import assert_almost_equal
  import torch
  from allennlp.common.testing import AllenNlpTestCase
  from allennlp.data import Vocabulary
  from allennlp.data.fields import KnowledgeGraphField
  from allennlp.data.token_indexers import SingleIdTokenIndexer, TokenCharactersIndexer
  from allennlp.data.tokenizers import WordTokenizer
  from allennlp.data.tokenizers.word_splitter import SpacyWordSplitter
  from allennlp.semparse.contexts import TableQuestionKnowledgeGraph
label_desc: Use image node_id 3 for calling the KnowledgeGraphFieldTest obj's underlying member method code with example usage: obj.test_index_converts_field_correctly() without return types