code: def test_sample_negative_weights(self, obj):
      # Check won't accept negative weights
      bad_weights = [-0.1] * 10
      msg = "weight vector many not include negative values"
      with pytest.raises(ValueError, match=msg):
          obj.sample(n=3, weights=bad_weights)
  
imports: import numpy
  import pytest
  from pandas import DataFrame, Index, Series
  import pandas._testing
  import pandas.core.common
label_desc: Use image node_id 9 for calling the TestSample obj's underlying member method code with example usage: obj.test_sample_negative_weights(obj) without return types