public UserProfile Add(UserProfile userProfile)
        {
            context.UserProfiles.Add(userProfile);
            context.SaveChanges();

            return userProfile;
        }
        public void Add()
        {
            var hulk = new UserProfile { FirstName = "Bruce", LastName = "Banner", EmailAddress = "*****@*****.**", FacebookId = "bruce.banner.hulk.facebookid", GoogleId = "bruce.banner.hulk.googleid" };

            var currentCount = context.UserProfiles.Count();

            var addUserProfile = userProfileRepository.Add(hulk);

            Assert.Equal(currentCount + 1, context.UserProfiles.Count());
            var foundUserProfile = context.UserProfiles.FirstOrDefault(x => x.Id == addUserProfile.Id);
            Assert.Equal(hulk.FirstName, foundUserProfile.FirstName);
            Assert.Equal(hulk.LastName, foundUserProfile.LastName);
            Assert.Equal(hulk.EmailAddress, foundUserProfile.EmailAddress);
            Assert.Equal(hulk.FacebookId, foundUserProfile.FacebookId);
            Assert.Equal(hulk.GoogleId, foundUserProfile.GoogleId);
        }
 public void Update(UserProfile userProfile)
 {
     context.UserProfiles.Update(userProfile);
     context.SaveChanges();
 }