code: def test_input_validation(self):
      message = "Lower and upper bounds must be dense arrays."
      with pytest.raises(ValueError, match=message):
          Bounds(sps.coo_array([1, 2]), [1, 2])
      with pytest.raises(ValueError, match=message):
          Bounds([1, 2], sps.coo_array([1, 2]))
  
      message = "`keep_feasible` must be a dense array."
      with pytest.raises(ValueError, match=message):
          Bounds(
              [1, 2], [1, 2], keep_feasible=sps.coo_array([True, True])
          )
  
      message = "`lb`, `ub`, and `keep_feasible` must be broadcastable."
      with pytest.raises(ValueError, match=message):
          Bounds([1, 2], [1, 2, 3])
  
imports: import pytest
  import numpy
  from numpy.testing import TestCase, assert_array_equal
  import scipy.sparse
  from scipy.optimize._constraints import Bounds, LinearConstraint, NonlinearConstraint, PreparedConstraint, new_bounds_to_old, old_bound_to_new, strict_bounds
label_desc: Use image node_id 4 for calling the TestBounds obj's underlying member method code with example usage: obj.test_input_validation() without return types