code: def test_create_pool_bad_slots(self):
      with pytest.raises(
          AirflowBadRequest, match="^Bad value for `slots`: foo$"
      ):
          pool_api.create_pool(
              name="foo",
              slots="foo",
              description="",
          )
  
imports: from __future__ import annotations
  import random
  import string
  import pytest
  from airflow import models
  from airflow.api.common.experimental import pool
  from airflow.exceptions import AirflowBadRequest, PoolNotFound
  from airflow.models.pool import Pool
  from airflow.utils.session import create_session
  from tests.test_utils.db import clear_db_pools
label_desc: Use image node_id 10 for calling the TestPool obj's underlying member method code with example usage: obj.test_create_pool_bad_slots() without return types