code: def _isoparse_date_and_time(
      dt, date_fmt, time_fmt, tzoffset, microsecond_precision=None
  ):
      tzi, offset_str = tzoffset
      fmt = date_fmt + "T" + time_fmt
      dt = dt.replace(tzinfo=tzi)
      dtstr = dt.strftime(fmt)
  
      if microsecond_precision is not None:
          if not fmt.endswith("%f"):  # pragma: nocover
              raise ValueError("Time format has no microseconds!")
  
          if microsecond_precision != 6:
              dtstr = dtstr[: -(6 - microsecond_precision)]
          elif microsecond_precision > 6:  # pragma: nocover
              raise ValueError("Precision must be 1-6")
  
      dtstr += offset_str
  
      assert isoparse(dtstr) == dt
  
imports: from __future__ import unicode_literals
  from datetime import datetime, timedelta, date, time
  import itertools
  from dateutil import tz
  from dateutil.tz import UTC
  from dateutil.parser import isoparser, isoparse
  import pytest
  import six
label_desc: Use image node_id 5 for calling a global function with example usage: _isoparse_date_and_time(dt, date_fmt, time_fmt, tzoffset, microsecond_precision) without return types