Package br.com.six2six.fixturefactory.function.impl

Examples of br.com.six2six.fixturefactory.function.impl.CpfFunction


public class CpfFunctionTest {

  @Test
  public void randomCpf() {
    String value = new CpfFunction().generateValue();
    assertNotNull("Generated CPF can not be null", value);
    assertTrue("Invalid match for CPF", Pattern.matches("\\d{11}", value));
  }
View Full Code Here


    assertTrue("Invalid match for CPF", Pattern.matches("\\d{11}", value));
  }

  @Test
  public void randomFormattedCpf() {
    String value = new CpfFunction(true).generateValue();
    assertNotNull("Generated formatted CPF can not be null", value);
    assertTrue("Invalid match for CPF", Pattern.matches("\\d{3}.\\d{3}.\\d{3}-\\d{2}", value));
  }
View Full Code Here

TOP

Related Classes of br.com.six2six.fixturefactory.function.impl.CpfFunction

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.