code: def skip_before_libpq(*ver):
      """Skip a test if libpq we're linked to is older than a certain version."""
      ver = ver + (0,) * (3 - len(ver))
  
      def skip_before_libpq_(cls):
          v = libpq_version()
          decorator = unittest.skipIf(
              v < int("%d%02d%02d" % ver),
              f"skipped because libpq {v}",
          )
          return decorator(cls)
  
      return skip_before_libpq_
  
imports: import re
  import os
  import sys
  import types
  import ctypes
  import select
  import operator
  import platform
  import unittest
  from functools import wraps
  from ctypes.util import find_library
  from io import StringIO
  from io import TextIOBase
  from importlib import reload
  import psycopg2
  import psycopg2.errors
  import psycopg2.extensions
  from .testconfig import green, dsn, repl_dsn
label_desc: Use image node_id 8 for calling a global function with example usage: skip_before_libpq() and returns: skip_before_libpq_, decorator