code: def test_bs_rng_errors(self):
      y = self.rng.random_sample(1000)
      bs_rng = BootstrapRng(y, 100)
      rng = bs_rng.rng()
      with pytest.raises(IndexError):
          for _ in range(100, 1001):
              rng(1)
  
      y = self.rng.random_sample(1000)
      with pytest.raises(ValueError):
          BootstrapRng(y, 0)
  
imports: import numpy
  from numpy.random import RandomState
  from numpy.testing import assert_allclose
  import pandas
  import pytest
  from arch.univariate import arch_model
  from arch.univariate.distribution import Normal, StudentsT
  from arch.univariate.mean import ConstantMean
  from arch.univariate.volatility import APARCH, EGARCH, FIGARCH, GARCH, HARCH, BootstrapRng, ConstantVariance, EWMAVariance, FixedVariance, MIDASHyperbolic, RiskMetrics2006
label_desc: Use image node_id 3 for calling the TestBootstrapRng obj's underlying member method code with example usage: obj.test_bs_rng_errors() without return types