code: def test_rank():
      """Test rank."""
      evaluator, metrics_by_strategy = evaluator_setup(
          score_function=accuracy_score
      )
      expected_ranks = pd.DataFrame(
          {
              "strategy": ["alg1", "alg2", "alg3"],
              "score_function_mean_rank": [1.0, 3.0, 2.0],
          }
      )
      generated_ranks = evaluator.rank()
      assert expected_ranks.equals(generated_ranks)
  
imports: import numpy
  import pandas
  import pytest
  from sklearn.metrics import accuracy_score
  from sktime.benchmarking.evaluation import Evaluator
  from sktime.benchmarking.metrics import PairwiseMetric
  from sktime.benchmarking.results import RAMResults
  from sktime.series_as_features.model_selection import PresplitFilesCV
  from sktime.utils.validation._dependencies import _check_soft_dependencies
label_desc: Use image node_id 3 for calling a global function with example usage: test_rank() without return types