Ejemplo n.º 1
0
        public async Task <string> GivenAValidUserId()
        {
            var createApiConfig = new CreateApi.Configuration(fixture);
            var user            = createApiConfig.GivenAValidUserModel();

            user.Email = "*****@*****.**";

            var response = await createApiConfig.WhenRequestingTheCreateUserApiAsync(user);

            var result = await createApiConfig.WhenGetContentAsModelAsync <UserModel>(response);

            return(result.Id);
        }
        public async Task <string> GivenAValidEmployeeId()
        {
            var createApiConfig = new CreateApi.Configuration(fixture);
            var employee        = createApiConfig.GivenAValidEmployeeModel();

            employee.Email = "*****@*****.**";

            var response = await createApiConfig.WhenRequestingTheCreateEmployeeApiAsync(employee);

            var result = await createApiConfig.WhenGetContentAsModelAsync <EmployeeModel>(response);

            return(result.Id);
        }