code: def testHaveDateAndVersion(self):
      # Test specific behavior when both Date and Version are present.
      split1 = os.path.join(
          self._input_base_path, "19700102", "ver1", "split1", "data"
      )
      io_utils.write_string_file(split1, "testing")
  
      splits = [
          example_gen_pb2.Input.Split(
              name="s1", pattern="{YYYY}{MM}{DD}/ver{VERSION}/split1/*"
          )
      ]
  
      (
          _,
          span,
          version,
      ) = utils.calculate_splits_fingerprint_span_and_version(
          self._input_base_path, splits
      )
      self.assertEqual(span, 1)
      self.assertEqual(version, 1)
  
imports: import os
  import re
  import tensorflow
  from tfx.components.example_gen import utils
  from tfx.dsl.io import fileio
  from tfx.orchestration import data_types
  from tfx.proto import example_gen_pb2
  from tfx.proto import range_config_pb2
  from tfx.utils import io_utils
  from tfx.utils import json_utils
label_desc: Use image node_id 24 for calling the UtilsTest obj's underlying member method code with example usage: obj.testHaveDateAndVersion() without return types