code: def test_int_np_regression():
      # Test int works as expected for integers.
      # We previously used a custom as_int() for integers because of a
      # numpy 1.4.1 bug such that int(np.uint32(2**32-1) == -1
      for t in sctypes["int"] + sctypes["uint"]:
          info = np.iinfo(t)
          mn, mx = np.array([info.min, info.max], dtype=t)
          assert (mn, mx) == (int(mn), int(mx))
  
file_path: nibabel/nibabel/tests/test_floating.py
imports: import sys
  from contextlib import nullcontext
  import numpy
  import pytest
  from packaging.version import Version
  from ..casting import FloatingError, _check_maxexp, _check_nmant, ceil_exact, floor_exact, floor_log2, have_binary128, longdouble_precision_improved, ok_floats, on_powerpc, sctypes, type_info
  from ..testing import suppress_warnings
label_desc: Use image node_id 6 for calling a global function with example usage: test_int_np_regression() without return types