code: def skip_if():
      """Fixture to skip tests."""
  
      def _skip_if(dev, capabilities):
          """Skip test if device has any of the given capabilities."""
  
          dev_capabilities = dev.capabilities()
          for capability, value in capabilities.items():
              # skip if capability not found, or if capability has specific value
              if (
                  capability not in dev_capabilities
                  or dev_capabilities[capability] == value
              ):
                  pytest.skip(
                      f"Test skipped for {dev.name} device with capability {capability}:{value}."
                  )
  
      return _skip_if
  
file_path: pennylane/pennylane/devices/tests/conftest.py
imports: import argparse
  import os
  import numpy
  import pytest
  from _pytest.runner import pytest_runtest_makereport
  import pennylane
label_desc: Use image node_id 3 for calling a global function with example usage: skip_if() and returns: _skip_if