code: def test_validate():
      vds = hl.vds.read_vds(
          os.path.join(resource("vds"), "1kg_chr22_5_samples.vds")
      )
      vds.validate()
  
      with pytest.raises(ValueError):
          hl.vds.VariantDataset(
              vds.reference_data.annotate_rows(arr=[0, 1]).explode_rows(
                  "arr"
              ),
              vds.variant_data,
          ).validate()
  
      with pytest.raises(ValueError):
          hl.vds.VariantDataset(
              vds.reference_data.annotate_entries(
                  END=hl.or_missing(
                      vds.reference_data.locus.position % 2 == 0,
                      vds.reference_data.END,
                  )
              ),
              vds.variant_data,
          ).validate()
  
imports: import os
  import pytest
  import hail
  from hail.utils import new_temp_file
  from hail.vds.combiner.combine import defined_entry_fields
  from ..helpers import resource, test_timeout, qobtest
label_desc: Use image node_id 2 for calling a global function with example usage: test_validate() without return types