code: def test_learning_rate(optimizer_class):
      lr = -0.01
      with pytest.raises(ValueError) as ctx:
          optimizer_class(None, lr=-0.01)
      msg = "Invalid learning rate: {}".format(lr)
      assert msg in str(ctx.value)
  
file_path: pytorch-optimizer/tests/test_param_validation.py
imports: import pytest
  import torch
  import torch_optimizer
label_desc: Use image node_id 3 for calling a global function with example usage: test_learning_rate(optimizer_class) without return types