code: def test_constant_rate_factor_error(
      art_warning, constant_rate_factor
  ):
      try:
          exc_msg = r"Constant rate factor must be an integer in the range \[0, 51\]."
          with pytest.raises(ValueError, match=exc_msg):
              VideoCompression(
                  video_format="",
                  constant_rate_factor=constant_rate_factor,
              )
      except ARTTestException as e:
          art_warning(e)
  
file_path: adversarial-robustness-toolbox/tests/defences/preprocessor/test_video_compression.py
imports: from __future__ import absolute_import, division, print_function, unicode_literals
  import logging
  import numpy
  import pytest
  from numpy.testing import assert_array_equal
  from art.defences.preprocessor import VideoCompression
  from tests.utils import ARTTestException
label_desc: Use image node_id 4 for calling a global function with example usage: test_constant_rate_factor_error(art_warning, constant_rate_factor) without return types