code: def test_kwargs(monkeypatch, records):
      is_multi_label = records[0].multi_label
  
      if parse_version(cleanlab.__version__) < parse_version("2.0"):
  
          def mock_get_noise_indices(s, psx, n_jobs, **kwargs):
              assert kwargs == {
                  "mock": "mock",
                  "multi_label": is_multi_label,
                  "sorted_index_method": "normalized_margin",
              }
              return []
  
          monkeypatch.setattr(
              "cleanlab.pruning.get_noise_indices",
              mock_get_noise_indices,
          )
  
          with pytest.raises(
              ValueError,
              match="'sorted_index_method' kwarg is not supported",
          ):
              find_label_errors(
                  records=records, sorted_index_method="mock"
              )
  
          find_label_errors(records=records, mock="mock")
      else:
  
          def mock_find_label_issues(s, psx, n_jobs, **kwargs):
              assert kwargs == {
                  "mock": "mock",
                  "multi_label": is_multi_label,
                  "return_indices_ranked_by": "normalized_margin"
                  if not is_multi_label
                  else "self_confidence",
              }
              return []
  
          monkeypatch.setattr(
              "cleanlab.filter.find_label_issues",
              mock_find_label_issues,
          )
  
          with pytest.raises(
              ValueError,
              match="'return_indices_ranked_by' kwarg is not supported",
          ):
              find_label_errors(
                  records=records, return_indices_ranked_by="mock"
              )
  
          find_label_errors(records=records, mock="mock")
  
imports: import sys
  import cleanlab
  import pytest
  from argilla import User
  from argilla.client.api import delete, load, log
  from argilla.client.models import TextClassificationRecord
  from argilla.client.singleton import init
  from argilla.labeling.text_classification import find_label_errors
  from argilla.labeling.text_classification.label_errors import MissingPredictionError, NoRecordsError, SortBy, _construct_s_and_psx
  from pkg_resources import parse_version
label_desc: Use image node_id 7 for calling a global function with example usage: test_kwargs(monkeypatch, records) and returns: list, list