code: def test_log1mexp_deprecation_warnings():
      with pytest.warns(
          FutureWarning,
          match="pymc.math.log1mexp_numpy will expect a negative input",
      ):
          res_pos = log1mexp_numpy(2)
  
      with warnings.catch_warnings():
          warnings.simplefilter("error")
          res_neg = log1mexp_numpy(-2, negative_input=True)
  
      with pytest.warns(
          FutureWarning,
          match="pymc.math.log1mexp will expect a negative input",
      ):
          res_pos_at = log1mexp(2).eval()
  
      with warnings.catch_warnings():
          warnings.simplefilter("error")
          res_neg_at = log1mexp(-2, negative_input=True).eval()
  
      assert np.isclose(res_pos, res_neg)
      assert np.isclose(res_pos_at, res_neg)
      assert np.isclose(res_neg_at, res_neg)
  
imports: import warnings
  import numpy
  import numpy.testing
  import pytensor
  import pytensor.tensor
  import pytest
  from pymc.math import LogDet, cartesian, expand_packed_triangular, invprobit, kron_dot, kron_solve_lower, kronecker, log1mexp, log1mexp_numpy, logdet, logdiffexp, logdiffexp_numpy, probit
  from pymc.pytensorf import floatX
  from tests.helpers import verify_grad
label_desc: Use image node_id 10 for calling a global function with example usage: test_log1mexp_deprecation_warnings() without return types