@Test
public void checkIfPrivateShapesAreReferenced() {

    Model model = Prelude.getPreludeModel();
    ModelTransformer transformer = ModelTransformer.create();
    Model result = transformer.scrubTraitDefinitions(model);
    Set<ShapeId> unreferencedPrivateShapes = result.shapes()
            .filter(shape -> shape.hasTrait(PrivateTrait.class))
            .map(Shape::getId)
            .collect(Collectors.toSet());
    assertThat(unreferencedPrivateShapes, emptyCollectionOf(ShapeId.class));
}