code: def test_duplicate_dataset_collections_on_notebooks():
      with mock.patch.object(py_utils, "is_notebook", lambda: True):
          name = "colab_dataset_collection_builder"
          assert (
              name not in registered.list_imported_dataset_collections()
          )
  
          class ColabDatasetCollectionBuilder(
              EmptyDatasetCollectionBuilder
          ):  # pylint: disable=unused-variable
              pass
  
          assert name in registered.list_imported_dataset_collections()
          cls = registered.imported_dataset_collection_cls(name)
          assert isinstance(cls, type(ColabDatasetCollectionBuilder))
          old_colab_cls = ColabDatasetCollectionBuilder
  
          class ColabDatasetCollectionBuilder(
              EmptyDatasetBuilder
          ):  # pylint: disable=function-redefined
              pass
  
          assert name in registered.list_imported_dataset_collections()
          assert isinstance(cls, type(ColabDatasetCollectionBuilder))
          assert not isinstance(cls, old_colab_cls)
  
imports: import abc
  import re
  from unittest import mock
  import pytest
  from tensorflow_datasets import testing
  from tensorflow_datasets.core import constants
  from tensorflow_datasets.core import load
  from tensorflow_datasets.core import registered
  from tensorflow_datasets.core import splits
  from tensorflow_datasets.core import utils
  from tensorflow_datasets.core.utils import py_utils
  import tensorflow_datasets.public_api
  from tensorflow_datasets.testing.dummy_config_based_datasets.dummy_ds_1 import dummy_ds_1_dataset_builder
label_desc: Use image node_id 12 for calling a global function with example usage: test_duplicate_dataset_collections_on_notebooks() without return types