code: def test_publish_data(mock_fs: testing.MockFs):
      builder = testing.DummyMnist(data_dir="/tmp")
      expected_from = epath.Path("/tmp") / "dummy_mnist/3.0.1"
      filename = "dataset_info.json"
      content = "a"
      mock_fs.add_file(path=expected_from / filename, content=content)
      publish_data_dir = epath.Path("/a/b")
      build_lib._publish_data(
          publish_data_dir=publish_data_dir, builder=builder
      )
      assert mock_fs.read_file(publish_data_dir / filename) == content
  
imports: import contextlib
  import os
  import pathlib
  from typing import Dict, Iterator, List, Optional
  from unittest import mock
  from absl.testing import parameterized
  from etils import epath
  import pytest
  import tensorflow_datasets
  from tensorflow_datasets import testing
  from tensorflow_datasets.core import download
  from tensorflow_datasets.core import utils
  from tensorflow_datasets.core.utils import file_utils
  from tensorflow_datasets.scripts.cli import build
  from tensorflow_datasets.scripts.cli import main
label_desc: Use image node_id 14 for calling a global function with example usage: test_publish_data(mock_fs) without return types