code: def test_port_not_available() -> None:
      sock = socket.socket()
      try:
          sock.bind(("0.0.0.0", 0))
          port = sock.getsockname()[1]
          out = check_error(["--port", str(port)])
          expected = f"Cannot start Bokeh server, port {port} is already in use"
          assert expected in out
      finally:
          sock.close()
  
imports: from __future__ import annotations
  import pytest
  import argparse
  import contextlib
  import os.path
  import re
  import socket
  import subprocess
  import sys
  import time
  from os.path import join, split
  from pathlib import Path
  from queue import Empty, Queue
  from threading import Thread
  import requests
  import requests_unixsocket
  from bokeh.command.subcommand import Argument
  from bokeh.resources import DEFAULT_SERVER_PORT
  from tests.support.util.env import envset
  import bokeh.command.subcommands.serve
label_desc: Use image node_id 14 for calling a global function with example usage: test_port_not_available() without return types