code: def test_globbedpaths_misses(path=None):
      gp = GlobbedPaths(["amiss"], pwd=path)
      eq_(gp.expand_strict(), [])
      eq_(gp.misses, ["amiss"])
      eq_(gp.expand(include_misses=True), ["amiss"])
  
      # miss at beginning
      gp = GlobbedPaths(["amiss", "*.txt", "*.dat"], pwd=path)
      eq_(gp.expand_strict(), ["1.txt", "3.txt", "2.dat"])
      eq_(
          gp.expand(include_misses=True),
          ["amiss", "1.txt", "3.txt", "2.dat"],
      )
  
      # miss in middle
      gp = GlobbedPaths(["*.txt", "amiss", "*.dat"], pwd=path)
      eq_(gp.expand_strict(), ["1.txt", "3.txt", "2.dat"])
      eq_(gp.misses, ["amiss"])
      eq_(
          gp.expand(include_misses=True),
          ["1.txt", "3.txt", "amiss", "2.dat"],
      )
  
      # miss at end
      gp = GlobbedPaths(["*.txt", "*.dat", "amiss"], pwd=path)
      eq_(gp.expand_strict(), ["1.txt", "3.txt", "2.dat"])
      eq_(gp.misses, ["amiss"])
      eq_(
          gp.expand(include_misses=True),
          ["1.txt", "3.txt", "2.dat", "amiss"],
      )
  
      # miss at beginning, middle, and end
      gp = GlobbedPaths(
          ["amiss1", "amiss2", "*.txt", "amiss3", "*.dat", "amiss4"],
          pwd=path,
      )
      eq_(gp.expand_strict(), ["1.txt", "3.txt", "2.dat"])
      eq_(gp.misses, ["amiss1", "amiss2", "amiss3", "amiss4"])
      eq_(
          gp.expand(include_misses=True),
          [
              "amiss1",
              "amiss2",
              "1.txt",
              "3.txt",
              "amiss3",
              "2.dat",
              "amiss4",
          ],
      )
  
      # Property expands if needed.
      gp = GlobbedPaths(["amiss"], pwd=path)
      eq_(gp.misses, ["amiss"])
  
file_path: datalad/datalad/support/tests/test_globbedpaths.py
imports: import logging
  import os.path
  from itertools import product
  from unittest.mock import patch
  from datalad.tests.utils_pytest import OBSCURE_FILENAME, assert_in, eq_, swallow_logs, with_tree
  from ..globbedpaths import GlobbedPaths
label_desc: Use image node_id 3 for calling a global function with example usage: test_globbedpaths_misses(path) without return types