code: def test_incumbents_any_budget(
      make_scenario, configspace_small, make_config_selector
  ):
      """Tests whether the incumbent is updated correctly."""
      scenario: Scenario = make_scenario(
          configspace_small,
          use_instances=False,
          min_budget=1,
          max_budget=3,
      )
      runhistory = RunHistory()
      intensifier = SuccessiveHalving(
          scenario=scenario,
          eta=3,
          n_seeds=1,
          instance_seed_order=None,
          incumbent_selection="any_budget",
      )
      intensifier.config_selector = make_config_selector(
          scenario, runhistory, n_initial_configs=1
      )
      intensifier.runhistory = runhistory
      config = configspace_small.get_default_configuration()
      config2 = configspace_small.sample_configuration(1)
  
      # Add some entries to the runhistory
      runhistory.add(
          config=config,
          cost=0.5,
          time=0.0,
          seed=8,
          budget=1,
          status=StatusType.SUCCESS,
      )
      intensifier.update_incumbents(config)
      assert intensifier.get_incumbent() == config
      assert intensifier.get_instance_seed_budget_keys(config) == [
          InstanceSeedBudgetKey(instance=None, seed=8, budget=1.0)
      ]
  
      runhistory.add(
          config=config2,
          cost=0.3,
          time=0.0,
          seed=8,
          budget=1,
          status=StatusType.SUCCESS,
      )
      intensifier.update_incumbents(config2)
      assert intensifier.get_incumbent() == config2
      assert intensifier.get_instance_seed_budget_keys(config2) == [
          InstanceSeedBudgetKey(instance=None, seed=8, budget=1.0)
      ]
  
      # Let's see what happens if we add another budget
      # We expect that all instance-seed-budget keys are used for the incumbent
      runhistory.add(
          config=config,
          cost=-9999,
          time=0.0,
          seed=8,
          budget=2,
          status=StatusType.SUCCESS,
      )
      intensifier.update_incumbents(config)
      assert intensifier.get_incumbent() == config
      assert intensifier.get_instance_seed_budget_keys(config) == [
          InstanceSeedBudgetKey(instance=None, seed=8, budget=1.0),
          InstanceSeedBudgetKey(instance=None, seed=8, budget=2.0),
      ]
  
      # If we want to compare the isb keys, we expect only one because giving the fact that config is already evaluated
      # on at least one budget. If we have evaluated on at least one budget, we are good to go.
      assert intensifier.get_instance_seed_budget_keys(
          config, compare=True
      ) == [InstanceSeedBudgetKey(instance=None, seed=8, budget=None)]
  
imports: import pytest
  from smac.initial_design.random_design import RandomInitialDesign
  from smac.intensifier.successive_halving import SuccessiveHalving
  from smac.main.config_selector import ConfigSelector
  from smac.runhistory.dataclasses import InstanceSeedBudgetKey
  from smac.runhistory.enumerations import StatusType
  from smac.runhistory.runhistory import RunHistory
  from smac.scenario import Scenario
label_desc: Use image node_id 6 for calling a global function with example usage: test_incumbents_any_budget(make_scenario, configspace_small, make_config_selector) without return types