### Question:
CompositeCalculationFunctions implements CalculationFunctions, ImmutableBean { static CompositeCalculationFunctions of(CalculationFunctions functions1, CalculationFunctions functions2) { return new CompositeCalculationFunctions(functions1, functions2); } private  CompositeCalculationFunctions(
      CalculationFunctions functions1,
      CalculationFunctions functions2); @Override Optional<CalculationFunction<? super T>> findFunction(T target); static TypedMetaBean<CompositeCalculationFunctions> meta(); @Override TypedMetaBean<CompositeCalculationFunctions> metaBean(); CalculationFunctions getFunctions1(); CalculationFunctions getFunctions2(); @Override boolean equals(Object obj); @Override int hashCode(); @Override String toString();  }### Answer:
@Test public void compose() { Fn1 fn1a = new Fn1(); Fn1 fn1b = new Fn1(); Fn2 fn2 = new Fn2(); CalculationFunctions fns1 = CalculationFunctions.of(fn1a); CalculationFunctions fns2 = CalculationFunctions.of(fn1b, fn2); CalculationFunctions composed = fns1.composedWith(fns2); assertThat(composed.getFunction(new Target1())).isEqualTo(fn1a); assertThat(composed.getFunction(new Target2())).isEqualTo(fn2); }