code: def test_get_trials_at_depth_given_existing_trial(self):
      population_size = 5
      generations = 10
      lineages = build_population(
          [
              list(range(population_size))
              for generation in range(generations)
          ]
      )
      for depth in [0, 1, 5, 9]:
          lineage_index = random.choice(range(population_size))
          trial = TrialStub(id=f"lineage-{lineage_index}-{depth}")
          compare_generations(
              lineages.get_trials_at_depth(trial),
              population_size,
              depth,
          )
  
imports: import os
  import random
  import pytest
  from base import ObjectiveStub, TrialStub, build_full_tree, build_population, compare_generations
  from orion.algo.pbt.pbt import LineageNode, Lineages
label_desc: Use image node_id 18 for calling the TestLineages obj's underlying member method code with example usage: obj.test_get_trials_at_depth_given_existing_trial() without return types