### Question:
PropertiesImpl implements Properties { @Override public Collection<Property> getProperties() { return flatMapEach(properties, TypedProperties::getProperties); }  static Properties flat(List<Properties> properties); @Override Properties resolveBy(Resolver resolver); @Override Properties withoutVars(); @Override Properties without(Predicate<Property> excluded); @Override Properties withPrefix(String prefix); @Override Map<String, Property> getPropertiesAsMap(); @Override Map<String, String> getPropertiesAsKeyValue(); @Override Collection<Property> getProperties(); @Override Optional<Property> getPropertyWithKey(String key); @Override List<T> save(PropertySerializer<T> serializer); @Override List<TypedProperties> asTypedProperties(); @Override TypedProperties first(); @Override Properties forEachComponent(UnaryOperator<TypedProperties> callback);  }### Answer:
@Test void getProperties() { Property p3 = getProperty(3); Property p1 = getProperty(1); Property p2 = getProperty(2); when(tp1.getProperties()).thenReturn(asList(p3, p1)); when(tp2.getProperties()).thenReturn(singletonList(p2)); assertEquals( of(p3, p1, p2).collect(toLinkedMap(Property::getKey, identity())), subj.getPropertiesAsMap() ); assertEquals( of(p3, p1, p2).collect(toLinkedMap(Property::getKey, Property::getValue)), subj.getPropertiesAsKeyValue() ); assertEquals( asList(p3, p1, p2), subj.getProperties() ); }