Package com.volantis.styling.impl.engine.matchers

Examples of com.volantis.styling.impl.engine.matchers.DefaultNamespaceMatcher



        // =====================================================================
        //   Test Expectations
        // =====================================================================
        DefaultNamespaceMatcher matcher = new DefaultNamespaceMatcher();
        MatcherResult result;

        // CDM namespace should match.
        matcherContextMock.expects.getNamespace()
                .returns(XDIMESchemata.CDM_NAMESPACE);
        result = matcher.matches(matcherContextMock);
        assertEquals(result, MatcherResult.MATCHED);

        // XHTML 2 namespace should match.
        matcherContextMock.expects.getNamespace()
                .returns(XDIMESchemata.XHTML2_NAMESPACE);
        result = matcher.matches(matcherContextMock);
        assertEquals(result, MatcherResult.MATCHED);

        // XForms namespace should not match.
        matcherContextMock.expects.getNamespace()
                .returns(XDIMESchemata.XFORMS_NAMESPACE);
        result = matcher.matches(matcherContextMock);
        assertEquals(result, MatcherResult.FAILED);
    }
View Full Code Here

TOP

Related Classes of com.volantis.styling.impl.engine.matchers.DefaultNamespaceMatcher

Copyright © 2018 www.massapicom. 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.