예제 #1
0
        /// <summary>
        /// Generate number of contacts for the specific User
        /// </summary>
        /// <param name="user">The user.</param>
        /// <param name="numberContacts">The number contacts.</param>
        public static void ContactsForUser(User user, int numberContacts)
        {
            for (int i = 0; i < numberContacts; i++)
            {
                string firstName = Faker.NameFaker.FirstName();
                string lastName  = Faker.NameFaker.LastName();
                string email     = Faker.StringFaker.Alpha(3) + Faker.InternetFaker.Email();
                string note      = Faker.CompanyFaker.BS();
                string phone     = Faker.PhoneFaker.Phone();
                string address   = Faker.LocationFaker.City() + ", " + Faker.LocationFaker.Street();

                ContactDAL.Create(user, firstName, lastName, email, note, phone, address);
            }
        }