public void AllViewModelFieldsAreSetFromConstructorTest() { // Arrange var projectUpdate = TestFramework.TestProjectUpdate.Create(); // Act var viewModel = new BasicsViewModel(projectUpdate, null); // Assert Assert.That(viewModel.ProjectDescription, Is.EqualTo(projectUpdate.ProjectDescription)); }
public void UpdateModelTest() { // Arrange var projectUpdate = TestFramework.TestProjectUpdate.Create(); var viewModel = new BasicsViewModel(projectUpdate, null); viewModel.ProjectDescription = TestFramework.MakeTestName(GeneralUtility.NameOf(() => viewModel.ProjectDescription), ProjectFirmaModels.Models.ProjectUpdate.FieldLengths.ProjectDescription); // Act viewModel.UpdateModel(projectUpdate, TestFramework.TestFirmaSession.Create()); // Assert Assert.That(projectUpdate.ProjectDescription, Is.EqualTo(viewModel.ProjectDescription)); }