Examples of differences()


Examples of net.javacrumbs.jsonunit.core.internal.Diff.differences()

        }

        public boolean matches(Object item) {
            Diff diff = create(expected, item, "fullJson", path, configuration);
            if (!diff.similar()) {
                differences = diff.differences();
            }
            return diff.similar();
        }

        public void describeTo(Description description) {
View Full Code Here

Examples of net.javacrumbs.jsonunit.core.internal.Diff.differences()

     * @see #isStringEqualTo(String)
     */
    public JsonFluentAssert isEqualTo(Object expected) {
        Diff diff = createDiff(expected, configuration);
        if (!diff.similar()) {
            failWithMessage(diff.differences());
        }
        return this;
    }


View Full Code Here

Examples of net.javacrumbs.jsonunit.core.internal.Diff.differences()

     * @return {@code this} object.
     */
    public JsonFluentAssert hasSameStructureAs(Object expected) {
        Diff diff = createDiff(expected, configuration.withOptions(COMPARING_ONLY_STRUCTURE));
        if (!diff.similar()) {
            failWithMessage(diff.differences());
        }
        return this;
    }

    /**
 
View Full Code Here

Examples of net.javacrumbs.jsonunit.core.internal.Diff.differences()

     * @param actual
     */
    public static void assertJsonStructureEquals(Object expected, Object actual) {
        Diff diff = create(expected, actual, ACTUAL, ROOT, configuration.withOptions(COMPARING_ONLY_STRUCTURE));
        if (!diff.similar()) {
            doFail(diff.differences());
        }
    }

    /**
     * Compares structure of part of the JSON. Path has this format "root.array[0].value".
View Full Code Here

Examples of net.javacrumbs.jsonunit.core.internal.Diff.differences()

     * @param path
     */
    public static void assertJsonPartStructureEquals(Object expected, Object fullJson, String path) {
        Diff diff = create(expected, fullJson, FULL_JSON, path, configuration.withOptions(COMPARING_ONLY_STRUCTURE));
        if (!diff.similar()) {
            doFail(diff.differences());
        }
    }

    /**
     * Fails if node in given path exists.
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.