code: def test_custom_temp_dir(monkeypatch: Any) -> None:
      test_temp_dir = "test_temp_dir"
      temp_dir = Path(tempfile.gettempdir()) / test_temp_dir
  
      monkeypatch.setenv("POLARS_VERBOSE", "1")
      monkeypatch.setenv("POLARS_FORCE_OOC", "1")
      monkeypatch.setenv("POLARS_TEMP_DIR", str(temp_dir))
  
      s = pl.arange(0, 100_000, eager=True).rename("idx")
      df = s.shuffle().to_frame()
      df.lazy().sort("idx").collect(streaming=True)
  
      assert os.listdir(
          temp_dir
      ), f"Temp directory '{temp_dir}' is empty"
  
imports: from __future__ import annotations
  import os
  import tempfile
  import time
  from datetime import date
  from pathlib import Path
  from typing import TYPE_CHECKING, Any
  import numpy
  import pytest
  import polars
  from polars.exceptions import PolarsInefficientMapWarning
  from polars.testing import assert_frame_equal
label_desc: Use image node_id 18 for calling a global function with example usage: test_custom_temp_dir(monkeypatch) without return types