code: def test_make_vocab_makes_vocab(self):
      vocab_path = self.TEST_DIR / "vocabulary"
  
      make_vocab_from_params(self.params, self.TEST_DIR)
  
      vocab_files = os.listdir(vocab_path)
      assert set(vocab_files) == set(
          ["labels.txt", "non_padded_namespaces.txt", "tokens.txt"]
      )
  
      with open(vocab_path / "tokens.txt") as f:
          tokens = [line.strip() for line in f]
  
      tokens.sort()
      assert tokens == [
          ".",
          "@@UNKNOWN@@",
          "animals",
          "are",
          "birds",
          "cats",
          "dogs",
          "snakes",
      ]
  
      with open(vocab_path / "labels.txt") as f:
          labels = [line.strip() for line in f]
  
      labels.sort()
      assert labels == ["N", "V"]
  
imports: from __future__ import with_statement
  from __future__ import division
  from __future__ import absolute_import
  import argparse
  import os
  import pytest
  from allennlp.common import Params
  from allennlp.common.testing import AllenNlpTestCase
  from allennlp.commands.make_vocab import MakeVocab, make_vocab_from_args, make_vocab_from_params
  from allennlp.data import Vocabulary
  from allennlp.common.checks import ConfigurationError
  from io import open
label_desc: Use image node_id 4 for calling the TestMakeVocab obj's underlying member method code with example usage: obj.test_make_vocab_makes_vocab() without return types