@Override
    protected void describeMismatchSafely(ShapeId item, Description mismatchDescription) {
        if (!result.getResult().isPresent()) {
            mismatchDescription.appendText("Model is broken: " + result.getValidationEvents().toString());
            return;
        }

        Model model = result.getResult().get();
        Shape shape = model.getShape(item).orElse(null);

        if (shape == null) {
            mismatchDescription.appendText("Shape " + item + " not found in the model");
        } else if (!shapeType.isInstance(shape)) {
            mismatchDescription.appendText("Shape " + item + " was " + shape.getClass() + " not " + shapeType);
        } else {
            S s = shapeType.cast(shape);
            for (Pair<Predicate<S>, Function<S, String>> pair : assertions) {
                if (!pair.left.test(s)) {
                    mismatchDescription.appendText(pair.right.apply(s));
                    return;
                }
            }
        }
    }
Creates a matcher that ensures a member is not marked with @default or @required.

@param result The validated result to check.
@return Returns the created matcher.
smithy-model/src/test/java/software/amazon/smithy/model/ShapeMatcher.java