Package org.auraframework.def

Examples of org.auraframework.def.ClientLibraryDef.validateDefinition()


        Set<AuraContext.Mode> modes = Collections.emptySet();

        try {
            def = vendor.makeClientLibraryDef(null, null, ClientLibraryDef.Type.JS, modes, false,
                    vendor.makeComponentDefDescriptor("comp"), vendor.makeLocation("f1", 5, 5, 0));
            def.validateDefinition();
            fail("Should have thrown InvalidDefinitionException for no name");
        } catch (Exception e) {
            checkExceptionFull(e, InvalidDefinitionException.class, "Must have either a name or url");
        }
View Full Code Here


        }

        try {
            def = vendor.makeClientLibraryDef("", null, ClientLibraryDef.Type.JS, modes, false,
                    vendor.makeComponentDefDescriptor("comp"), vendor.makeLocation("f1", 5, 5, 0));
            def.validateDefinition();
            fail("Should have thrown InvalidDefinitionException for Empty name");
        } catch (Exception e) {
            checkExceptionFull(e, InvalidDefinitionException.class, "Must have either a name or url");
        }
View Full Code Here

        }

        try {
            def = vendor.makeClientLibraryDef("hello", null, null, modes, false,
                    vendor.makeComponentDefDescriptor("comp"), vendor.makeLocation("f1", 5, 5, 0));
            def.validateDefinition();
            fail("Should have thrown InvalidDefinitionException for no type");
        } catch (Exception e) {
            checkExceptionFull(e, InvalidDefinitionException.class, "Missing required type");
        }
View Full Code Here

        }

        try {
            def = vendor.makeClientLibraryDef("hello", null, ClientLibraryDef.Type.JS, modes, false,
                    null, vendor.makeLocation("f1", 5, 5, 0));
            def.validateDefinition();
            fail("Should have thrown InvalidDefinitionException for no parent descriptor");
        } catch (Exception e) {
            checkExceptionFull(e, InvalidDefinitionException.class, "No parent for ClientLibraryDef");
        }
View Full Code Here

        }

        try {
            def = vendor.makeClientLibraryDef("hello", "somewhere/somefile.css", ClientLibraryDef.Type.JS, modes, false,
                    vendor.makeComponentDefDescriptor("comp"), vendor.makeLocation("f1", 5, 5, 0));
            def.validateDefinition();
            fail("Should have thrown InvalidDefinitionException for invalid file extension ");
        } catch (Exception e) {
            checkExceptionFull(e, InvalidDefinitionException.class, "Url file extension must match type");
        }
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.