public Person[] Build(int count, string domain)
        {
            Person[] people = new Person[count];

            for (int i = 0; i < count; i++)
            {
                people[i] = new Person()
                {
                    Age        = new Random().Next(18, 100),
                    Name       = personNameGenerator.GenerateRandomFirstAndLastName(),
                    Occupation = occupationGeneratorService.GetRandomOccupation()
                };

                people[i].Href = domain + "/api/people/" + people[i].ID;
            }

            return(people);
        }
Example #2
0
        public void GenerateClientsPocket()
        {
            var pockets = new List <Pocket>();

            for (var i = 0; i < Settings.NumbersOfClients; i++)
            {
                var pocket = new Pocket
                {
                    OwnerName = personGenerator.GenerateRandomFirstAndLastName()
                };
                pockets.Add(pocket);
            }

            Datas.Pockets = pockets;
        }