class_docstr: Tests for ConcurrencyCapBackpressurePolicy.
class_docstr_tok: ["Tests","for","ConcurrencyCapBackpressurePolicy","."]
code: def setUpClass(cls):
      cls._cluster_cpus = 10
      ray.init(num_cpus=cls._cluster_cpus)
      data_context = ray.data.DataContext.get_current()
      data_context.set_config(
          ENABLED_BACKPRESSURE_POLICIES_CONFIG_KEY,
          [ConcurrencyCapBackpressurePolicy],
      )
  
imports: import functools
  import time
  import unittest
  from collections import defaultdict
  from contextlib import contextmanager
  from unittest.mock import MagicMock, patch
  import numpy
  import pytest
  import ray
  from ray.data._internal.execution.backpressure_policy import ENABLED_BACKPRESSURE_POLICIES_CONFIG_KEY, ConcurrencyCapBackpressurePolicy, StreamingOutputBackpressurePolicy
  from ray.data.tests.conftest import restore_data_context
  from ray.data.tests.conftest import CoreExecutionMetrics, assert_core_execution_metrics_equals, get_initial_core_execution_metrics_snapshot
  from ray.tests.conftest import shutdown_only
label_desc: Use image node_id 1 for calling the TestConcurrencyCapBackpressurePolicy obj's underlying member method code with example usage: obj.setUpClass(cls) without return types