Package org.springmodules.web.test.domain

Examples of org.springmodules.web.test.domain.IEmployee


        super(testName);
    }

    public void testGetAsText() {
        ReflectivePropertyEditor editor = (ReflectivePropertyEditor) this.applicationContext.getBean("employeeEditor");
        IEmployee employee = this.repository.getEmployee("1");
        editor.setValue(employee);
        assertEquals(employee.getMatriculationCode(), editor.getAsText());
    }
View Full Code Here


        assertEquals(employee.getMatriculationCode(), editor.getAsText());
    }

    public void testSetAsText() {
        ReflectivePropertyEditor editor = (ReflectivePropertyEditor) this.applicationContext.getBean("employeeEditor");
        IEmployee employee = this.repository.getEmployee("1");
        editor.setAsText("1");
        assertEquals(employee, editor.getValue());
    }
View Full Code Here

        assertEquals(employee, editor.getValue());
    }
   
    public void testSetAsTextWithStringConvertor() {
        ReflectivePropertyEditor editor = (ReflectivePropertyEditor) this.applicationContext.getBean("employeesByOfficeEditor");
        IEmployee employee = this.repository.getEmployee("1");
        editor.setAsText("1");
        assertNotNull(editor.getValue());
        assertEquals(2, ((List) editor.getValue()).size());
    }
View Full Code Here

        return suite;
    }

    public void testSetCustomEditorsWithDefaultPrefix()
    throws Exception {
        IEmployee emp = new Employee();
        EnhancedAbstractWizardFormController controller = (EnhancedAbstractWizardFormController) this.applicationContext.getBean("testCustomEditorsWizardControllerOne");
        ServletRequestDataBinder binder = new ServletRequestDataBinder(emp);
       
        controller.initBinder(new MockHttpServletRequest(), binder);
       
View Full Code Here

        assertNotNull(binder.findCustomEditor(Office.class, null));
    }
   
    public void testSetCustomEditorsWithClassPrefix()
    throws Exception {
        IEmployee emp = new Employee();
        EnhancedAbstractWizardFormController controller = (EnhancedAbstractWizardFormController) this.applicationContext.getBean("testCustomEditorsWizardControllerTwo");
        ServletRequestDataBinder binder = new ServletRequestDataBinder(emp);
       
        controller.initBinder(new MockHttpServletRequest(), binder);
       
View Full Code Here

        assertNotNull(binder.findCustomEditor(Office.class, null));
    }
   
    public void testSetCustomEditorsWithPropertyPrefix()
    throws Exception {
        IEmployee emp = new Employee();
        EnhancedAbstractWizardFormController controller = (EnhancedAbstractWizardFormController) this.applicationContext.getBean("testCustomEditorsWizardControllerThree");
        ServletRequestDataBinder binder = new ServletRequestDataBinder(emp);
       
        controller.initBinder(new MockHttpServletRequest(), binder);
       
View Full Code Here

        assertNotNull(binder.findCustomEditor(null, "office"));
    }
   
    public void testSetCustomEditorsWithFailure()
    throws Exception {
        IEmployee emp = new Employee();
        EnhancedAbstractWizardFormController controller = (EnhancedAbstractWizardFormController) this.applicationContext.getBean("testCustomEditorsWizardControllerFour");
        ServletRequestDataBinder binder = new ServletRequestDataBinder(emp);
       
        try {
            controller.initBinder(new MockHttpServletRequest(), binder);
View Full Code Here

        return suite;
    }

    public void testSetCustomEditorsWithDefaultPrefix()
    throws Exception {
        IEmployee emp = new Employee();
        EnhancedSimpleFormController controller = (EnhancedSimpleFormController) this.applicationContext.getBean("testCustomEditorsControllerOne");
        ServletRequestDataBinder binder = new ServletRequestDataBinder(emp);
       
        controller.initBinder(new MockHttpServletRequest(), binder);
       
View Full Code Here

        assertNotNull(binder.findCustomEditor(Office.class, null));
    }
   
    public void testSetCustomEditorsWithClassPrefix()
    throws Exception {
        IEmployee emp = new Employee();
        EnhancedSimpleFormController controller = (EnhancedSimpleFormController) this.applicationContext.getBean("testCustomEditorsControllerTwo");
        ServletRequestDataBinder binder = new ServletRequestDataBinder(emp);
       
        controller.initBinder(new MockHttpServletRequest(), binder);
       
View Full Code Here

        assertNotNull(binder.findCustomEditor(Office.class, null));
    }
   
    public void testSetCustomEditorsWithPropertyPrefix()
    throws Exception {
        IEmployee emp = new Employee();
        EnhancedSimpleFormController controller = (EnhancedSimpleFormController) this.applicationContext.getBean("testCustomEditorsControllerThree");
        ServletRequestDataBinder binder = new ServletRequestDataBinder(emp);
       
        controller.initBinder(new MockHttpServletRequest(), binder);
       
View Full Code Here

TOP

Related Classes of org.springmodules.web.test.domain.IEmployee

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.