code: def test_convert_positional_args_future_warning() -> None:
      previous_positional_arg_names: List[str] = ["a", "b"]
      decorator_converter = convert_positional_args(
          previous_positional_arg_names=previous_positional_arg_names
      )
      assert callable(decorator_converter)
  
      decorated_func = decorator_converter(_sample_func)
      with pytest.warns(FutureWarning) as record:
          decorated_func(1, 2, c=3)  # type: ignore
          decorated_func(1, b=2, c=3)  # type: ignore
          decorated_func(a=1, b=2, c=3)  # No warning.
  
      assert len(record) == 2
      for warn in record.list:
          assert isinstance(warn.message, FutureWarning)
          assert _sample_func.__name__ in str(warn.message)
  
file_path: optuna/tests/test_convert_positional_args.py
imports: import re
  from typing import List
  import pytest
  from optuna._convert_positional_args import convert_positional_args
label_desc: Use image node_id 4 for calling a global function with example usage: test_convert_positional_args_future_warning() without return types