Ejemplo n.º 1
0
        public void VerifyThatPropertiesAreSet()
        {
            var shortname    = "new shortname";
            var name         = "new name";
            var isdeprecated = true;

            var simpleUnit = new SimpleUnit(Guid.NewGuid(), null, null);
            var vm         = new SimpleUnitDialogViewModel(simpleUnit, this.transaction, this.session.Object, true, ThingDialogKind.Inspect, this.dialogService.Object, this.genericSiteReferenceDataLibrary);

            Assert.IsFalse(vm.OkCommand.CanExecute(null));

            vm.ShortName    = shortname;
            vm.Name         = name;
            vm.IsDeprecated = isdeprecated;
            vm.Container    = this.genericSiteReferenceDataLibrary;

            Assert.IsTrue(vm.OkCommand.CanExecute(null));
        }
Ejemplo n.º 2
0
        public void VerifyThatParameterlessContructorExists()
        {
            var dialogViewModel = new SimpleUnitDialogViewModel();

            Assert.IsFalse(dialogViewModel.IsDeprecated);
        }