Documentation ¶
Index ¶
- func IsValidFakeDataAddress(address string) (bool, error)
- func IsValidFakeDataAddressStrict(address string) (bool, error)
- func IsValidFakeDataEmail(email string) (bool, error)
- func IsValidFakeDataFullName(firstName string, lastName string) (bool, error)
- func IsValidFakeDataFullNameStrict(firstName string, lastName string) (bool, error)
- func IsValidFakeDataName(name string) (bool, error)
- func IsValidFakeDataPhone(phone string) (bool, error)
- func RandomName() (first string, last string)
- func RandomStreetAddress() string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func IsValidFakeDataAddress ¶
IsValidFakeDataAddress checks the that the address can be found in the fake data. If the address is found true is returned, if not found, false is returned.
This function will compare using case insensitive comparison, but spaces and all characters not in the range a-z, A-Z, 0-9 will be removed and not used in the comparison. This will allow forgiveness of use of spaces, ',', '#' etc and other non alphabet characters.
func IsValidFakeDataAddressStrict ¶
IsValidFakeDataAddressStrict checks the that the address can be found in the fake data. If the address is found true is returned, if not found, false is returned.
This function will compare using case insensitive comparison, but spaces and all characters will be compared.
func IsValidFakeDataEmail ¶
IsValidFakeDataEmail - checks for the format @truss.works or @example.com or @email.com
func IsValidFakeDataFullName ¶
IsValidFakeDataFullName checks the first name and last name can be found in the fake data. If the name is found true is returned, if not found, false is returned.
This function will compare using case insensitive comparison, but spaces and all characters not in the range a-z, A-Z, 0-9 will be removed and not used in the comparison. This will allow forgiveness of use of spaces, ',', '#' etc and other non alphabet characters.
func IsValidFakeDataFullNameStrict ¶
IsValidFakeDataFullNameStrict checks the first name and last name can be found in the fake data. If the name is found true is returned, if not found, false is returned.
This function will compare using case insensitive comparison, but spaces and all characters will be compared.
func IsValidFakeDataName ¶
IsValidFakeDataName checks the name can be found in the fake data. If the name is found true is returned, if not found, false is returned. Name is assumed to be `firstName lastName`
This function will compare using case insensitive comparison, but spaces and all characters not in the range a-z, A-Z, 0-9 will be removed and not used in the comparison. This will allow forgiveness of use of spaces, ',', '#' etc and other non alphabet characters.
func IsValidFakeDataPhone ¶
IsValidFakeDataPhone - checks for the format
"999-999-999" or "###-555-####"
func RandomName ¶
RandomName - randomly selects a name from the fakeNames slice and returns the first and last name "Jason", "Ash"
func RandomStreetAddress ¶
func RandomStreetAddress() string
RandomStreetAddress - randomly selects a street address from the fakeAddress slice
Types ¶
This section is empty.