Package org.magicbox.core.factory

Examples of org.magicbox.core.factory.UserAbstractFactory


    }

    @Test
    public void allEmpty() {

        UserAbstractFactory factory = new UserFactoryDefaultImpl();
        CenterUserCommand command = factory.createUserCommand();
        command.setZipCode("");
        command.setCity("");
        command.setCountry("");
        command.setProvince("");
        command.setRegion("");
View Full Code Here


        assertTrue(errors.getErrorCount() == 2);
    }

    @Test
    public void mandatoryCorrect() {
        UserAbstractFactory factory = new UserFactoryDefaultImpl();
        CenterUserCommand command = factory.createUserCommand();
        command.setZipCode("09100");
        command.setCity("Cagliari");
        command.setCountry("Campidano");
        command.setProvince("CA");
        command.setRegion("Sardegna");
View Full Code Here

        assertTrue(errors.getErrorCount() == 0);
    }

    @Test
    public void allPossibleWrong() {
        UserAbstractFactory factory = new UserFactoryDefaultImpl();
        CenterUserCommand command = factory.createUserCommand();
        command.setZipCode("S");
        command.setCity("1");
        command.setCountry("I");
        command.setProvince("I");
        command.setRegion("S");
View Full Code Here

    }

    @Test
    public void testNameWrong() {

        UserAbstractFactory factory = new UserFactoryDefaultImpl();
        CenterUserCommand command = factory.createUserCommand();
        command.setZipCode("09100");
        command.setCity("Cagliari");
        command.setCountry("Campidano");
        command.setProvince("CA");
        command.setRegion("Sardegna");
View Full Code Here

    }

    @Test
    public void testZipCodeWrong() {
       
        UserAbstractFactory factory = new UserFactoryDefaultImpl();
        CenterUserCommand command = factory.createUserCommand();
        command.setZipCode("av");
        command.setCity("Cagliari");
        command.setCountry("Campidano");
        command.setProvince("CA");
        command.setRegion("Sardegna");
View Full Code Here

    }

    @Test
    public void testMobileWrong() {
       
        UserAbstractFactory factory = new UserFactoryDefaultImpl();
        CenterUserCommand command = factory.createUserCommand();
        command.setZipCode("09100");
        command.setCity("Cagliari");
        command.setCountry("Campidano");
        command.setProvince("CA");
        command.setRegion("Sardegna");
View Full Code Here

    }

    @Test
    public void testCityWrong() {
       
        UserAbstractFactory factory = new UserFactoryDefaultImpl();
        CenterUserCommand command = factory.createUserCommand();
        command.setZipCode("09100");
        command.setCity("Ca");
        command.setCountry("Campidano");
        command.setProvince("CA");
        command.setRegion("Sardegna");
View Full Code Here

    }

    @Test
    public void testEmailWrong() {
       
        UserAbstractFactory factory = new UserFactoryDefaultImpl();
        CenterUserCommand command = factory.createUserCommand();
        command.setZipCode("09100");
        command.setCity("Cagliari");
        command.setCountry("Campidano");
        command.setProvince("CA");
        command.setRegion("Sardegna");
View Full Code Here

        assertTrue(errors.getErrorCount() == 1);
    }

    @Test
    public void testStreetWrong() {
        UserAbstractFactory factory = new UserFactoryDefaultImpl();
        CenterUserCommand command = factory.createUserCommand();
        command.setZipCode("09100");
        command.setCity("Cagliari");
        command.setCountry("Campidano");
        command.setProvince("CA");
        command.setRegion("Sardegna");
View Full Code Here

        assertTrue(errors.getErrorCount() == 1);
    }

    @Test
    public void testProvinceWrong() {
        UserAbstractFactory factory = new UserFactoryDefaultImpl();
        CenterUserCommand command = factory.createUserCommand();
        command.setZipCode("09100");
        command.setCity("Cagliari");
        command.setCountry("Campidano");
        command.setProvince("1");
        command.setRegion("Sardegna");
View Full Code Here

TOP

Related Classes of org.magicbox.core.factory.UserAbstractFactory

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.