code: def test_zip_archive(path=None):
      ds = Dataset(opj(path, "ds")).create(force=True, annex=False)
      ds.save()
      with chpwd(path):
          ds.export_archive(filename="my", archivetype="zip")
          assert_true(os.path.exists("my.zip"))
          custom1_md5 = md5sum("my.zip")
          time.sleep(1.1)
          ds.export_archive(filename="my", archivetype="zip")
          assert_equal(md5sum("my.zip"), custom1_md5)
  
      # should be able to export without us cd'ing to that ds directory
      ds.export_archive(filename=ds.path, archivetype="zip")
      default_name = "datalad_{}.zip".format(ds.id)
      assert_true(os.path.exists(os.path.join(ds.path, default_name)))
  
file_path: datalad/datalad/local/tests/test_export_archive.py
imports: import os
  import tarfile
  import time
  from os.path import isabs
  from os.path import join
  from datalad.api import Dataset, export_archive
  from datalad.tests.utils_pytest import assert_equal, assert_false, assert_not_equal, assert_raises, assert_result_count, assert_status, assert_true, ok_startswith, with_tree
  from datalad.utils import chpwd, md5sum
label_desc: Use image node_id 3 for calling a global function with example usage: test_zip_archive(path) without return types