code: def test_fit_skips_superfluous_transforms(self):
      # given
      data = constant_timeseries(value=0, length=100)
      transformers = (
          [self.DataTransformerMock1() for _ in range(10)]
          + [self.DataTransformerMock2()]
          + [self.DataTransformerMock1() for _ in range(10)]
      )
      p = Pipeline(transformers)
  
      # when
      p.fit(data)
  
      # then
      for i in range(10):
          assert transformers[i].transform_called
      assert transformers[10].fit_called
      assert not transformers[10].transform_called
      for i in range(11, 21):
          assert not transformers[i].transform_called
  
imports: from typing import Any, Mapping
  import pytest
  from darts import TimeSeries
  from darts.dataprocessing import Pipeline
  from darts.dataprocessing.transformers import BaseDataTransformer, FittableDataTransformer, InvertibleDataTransformer, InvertibleMapper, Mapper
  from darts.utils.timeseries_generation import constant_timeseries
label_desc: Use image node_id 5 for calling the TestPipeline obj's underlying member method code with example usage: obj.test_fit_skips_superfluous_transforms() without return types