code: def test_reading(self):
      info = dataset_info.DatasetInfo(builder=self._builder)
      info.read_from_directory(_INFO_DIR)
  
      # Assert that we read the file and initialized DatasetInfo.
      self.assertTrue(info.initialized)
      self.assertEqual("mnist", info.name)
      self.assertEqual("mnist/3.0.1", info.full_name)
  
      # Test splits are initialized properly.
      split_dict = info.splits
  
      # Assert they are the correct number.
      self.assertTrue(len(split_dict), 2)
  
      # Assert on what they are
      self.assertIn("train", split_dict)
      self.assertIn("test", split_dict)
  
      # Assert that this is computed correctly.
      self.assertEqual(40, info.splits.total_num_examples)
      self.assertEqual(11594722, info.dataset_size)
  
      self.assertEqual("image", info.supervised_keys[0])
      self.assertEqual("label", info.supervised_keys[1])
      self.assertEqual(
          info.module_name,
          "tensorflow_datasets.image_classification.mnist",
      )
      self.assertEqual(False, info.disable_shuffling)
  
      self.assertEqual(info.version, utils.Version("3.0.1"))
      self.assertEqual(info.release_notes, {})
  
imports: import json
  import os
  import pathlib
  import tempfile
  import time
  from typing import Union
  import numpy
  import pytest
  import tensorflow
  from tensorflow_datasets import testing
  from tensorflow_datasets.core import dataset_builder
  from tensorflow_datasets.core import dataset_info
  from tensorflow_datasets.core import features
  from tensorflow_datasets.core import file_adapters
  from tensorflow_datasets.core import naming
  from tensorflow_datasets.core import read_only_builder
  from tensorflow_datasets.core import splits
  from tensorflow_datasets.core import utils
  from tensorflow_datasets.core.proto import dataset_info_pb2
  from tensorflow_datasets.core.proto import feature_pb2
  from tensorflow_datasets.image_classification import mnist
  from tensorflow_datasets.testing.dummy_config_based_datasets.dummy_ds_1 import dummy_ds_1_dataset_builder
  from google.protobuf import text_format
label_desc: Use image node_id 5 for calling the DatasetInfoTest obj's underlying member method code with example usage: obj.test_reading() without return types