public void NotifyPropertyChangedTests() { var vm = new SectionViewModel(); vm.Init(new DetailsViewModel()); TestsHelper.TestPublicPropertiesGetSet(vm); TestsHelper.TestPropertyWithNotifyPropertyChanged(vm, () => vm.IsVisible); }
public void SectionPaperclips_HasOnlySectionItems() { var sectionGuid = Guid.NewGuid(); var vm = new SectionViewModel(); vm.Init(new DetailsViewModel()); vm.Guid = sectionGuid; vm.Paperclips.Add(new PaperclipStub {SectionGuid = sectionGuid.ToString()}); vm.Paperclips.Add(new PaperclipStub {SectionGuid = Guid.NewGuid().ToString()}); vm.Paperclips.Add(new PaperclipStub {SectionGuid = Guid.NewGuid().ToString()}); vm.Paperclips.Add(new PaperclipStub {SectionGuid = sectionGuid.ToString()}); vm.Paperclips.Add(new PaperclipStub {SectionGuid = sectionGuid.ToString()}); Assert.AreEqual(3, vm.SectionPaperclips.Count); }