class_docstr: Tests for the `RegistryMapping` class. The RegistryMapping should act as a
  Mapping[Trial, list[Trial]].
class_docstr_tok: ["Tests","for","the","`","RegistryMapping","`","class",".","The","RegistryMapping","should","act","as","a","Mapping","[","Trial",",","list","[","Trial","]","]","."]
docstr: Test that externally registering trials in the original or transformed registries does
  not affect the length of the mapping.
docstr_tok: ["Test","that","externally","registering","trials","in","the","original","or","transformed","registries","does","not","affect","the","length","of","the","mapping","."]
code: def test_extenal_register_doesnt_increase_len(
      self, space: Space, transformed_space: TransformedSpace
  ):
      """Test that externally registering trials in the original or transformed registries does
      not affect the length of the mapping.
      """
      original = Registry()
      transformed = Registry()
      mapping = RegistryMapping(
          original_registry=original, transformed_registry=transformed
      )
      assert not mapping
      assert len(mapping) == 0
  
      original_trial = space.sample(1)[0]
      original.register(original_trial)
      assert not mapping
  
      transformed_trial = transformed_space.sample(1)[0]
      transformed.register(transformed_trial)
      assert not mapping
  
imports: import copy
  import pytest
  from orion.algo.base.registry import Registry, RegistryMapping
  from orion.algo.space import Space
  from orion.core.io.space_builder import SpaceBuilder
  from orion.core.worker.transformer import TransformedSpace, build_required_space
  from orion.core.worker.trial import Trial
label_desc: Use image node_id 2 for calling the TestRegistryMapping obj's underlying member method code with example usage: obj.test_extenal_register_doesnt_increase_len(space, transformed_space) without return types