Package org.richfaces.javascript

Examples of org.richfaces.javascript.ScriptNotFoundException


    @Test()
    public void testGetClientSideScriptNotExists() throws Throwable {
        expect((Class) descriptor.getImplementationClass()).andReturn(RegexValidator.class);
        expect(scriptService.getScript(environment.getFacesContext(), RegexValidator.class)).andThrow(
            new ScriptNotFoundException());

        controller.replay();
        Collection<? extends LibraryScriptFunction> clientSideValidatorScript = renderer.getClientSideValidatorScript(
            environment.getFacesContext(), descriptors);
        assertTrue(clientSideValidatorScript.isEmpty());
View Full Code Here


    @Test(expected = ScriptNotFoundException.class)
    public void testGetClientSideConverterScriptNotExists() throws Throwable {
        expect((Class) converterDescriptor.getImplementationClass()).andReturn(NumberConverter.class);
        expect(scriptService.getScript(environment.getFacesContext(), NumberConverter.class)).andThrow(
            new ScriptNotFoundException());
        controller.replay();
        renderer.getClientSideConverterScript(environment.getFacesContext(), converterDescriptor);
        controller.verify();
    }
View Full Code Here

        return new ClientValidatorRenderer() {
            @Override
            LibraryScriptFunction getClientSideConverterScript(FacesContext facesContext, ConverterDescriptor converter)
                    throws ScriptNotFoundException {
                if (null == converterFunction) {
                    throw new ScriptNotFoundException();
                }
                return converterFunction;
            }

            @Override
View Full Code Here

    @Test()
    public void testGetClientSideScriptNotExists() throws Throwable {
        expect((Class) descriptor.getImplementationClass()).andReturn(RegexValidator.class);
        expect(scriptService.getScript(environment.getFacesContext(), RegexValidator.class)).andThrow(
            new ScriptNotFoundException());

        controller.replay();
        Collection<? extends LibraryScriptFunction> clientSideValidatorScript = renderer.getClientSideValidatorScript(
            environment.getFacesContext(), descriptors);
        assertTrue(clientSideValidatorScript.isEmpty());
View Full Code Here

    @Test(expected = ScriptNotFoundException.class)
    public void testGetClientSideConverterScriptNotExists() throws Throwable {
        expect((Class) converterDescriptor.getImplementationClass()).andReturn(NumberConverter.class);
        expect(scriptService.getScript(environment.getFacesContext(), NumberConverter.class)).andThrow(
            new ScriptNotFoundException());
        controller.replay();
        renderer.getClientSideConverterScript(environment.getFacesContext(), converterDescriptor);
        controller.verify();
    }
View Full Code Here

        return new ClientValidatorRenderer() {
            @Override
            LibraryScriptFunction getClientSideConverterScript(FacesContext facesContext, ConverterDescriptor converter)
                    throws ScriptNotFoundException {
                if (null == converterFunction) {
                    throw new ScriptNotFoundException();
                }
                return converterFunction;
            }

            @Override
View Full Code Here

TOP

Related Classes of org.richfaces.javascript.ScriptNotFoundException

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.