public void ShouldUpdateProfile() { IVRProfile profile = new IVRProfile() { ProfileId = 11112, Culture = "en", PIN = "1234", FullName = "Basil", PhoneNumber = "+22222221" }; ProfileRepository repository = new ProfileRepository(DEVELOPMENT_CONNECTION_STRING); var createdEntity = repository.Create(profile); createdEntity.Culture = "fr"; createdEntity.PhoneNumber = "+1111112"; createdEntity.PIN = "4321"; repository.Update(createdEntity); var updatedEntity = repository.Get(11112); Assert.AreEqual(createdEntity.Culture, updatedEntity.Culture); Assert.AreEqual(createdEntity.PhoneNumber, updatedEntity.PhoneNumber); Assert.AreEqual(createdEntity.PIN, updatedEntity.PIN); }
public void ShouldReturnUserProfile() { int userId = 123456; ProfileRepository repository = new ProfileRepository(DEVELOPMENT_CONNECTION_STRING); var user = repository.Get(userId); Assert.IsNotNull(user); }