public void TestInitialize()
 {
     _toolMock         = new Mock <IToolDescriptor>();
     _warewolfTypeMock = new Mock <IWarewolfType>();
     _warewolfTypeMock.SetupGet(it => it.FullyQualifiedName).Returns("");
     _toolMock.SetupGet(it => it.Activity).Returns(_warewolfTypeMock.Object);
     _target = new ToolDescriptorViewModel(_toolMock.Object, false);
 }
        public void TestIsEnabledtrue()
        {
            //arrange
            _target = new ToolDescriptorViewModel(_toolMock.Object, true);

            //act
            var value = _target.IsEnabled;

            //assert
            Assert.IsTrue(value);
        }
        public void TestActivityFlowSwitchString()
        {
            //arrange
            _warewolfTypeMock.SetupGet(it => it.FullyQualifiedName).Returns(typeof(DsfFlowSwitchActivity).FullName);
            _target = new ToolDescriptorViewModel(_toolMock.Object, false);

            //act
            var value = _target.ActivityType as DataObject;

            //assert
            var formats = value.GetFormats();
            Assert.IsNotNull(formats);
            Assert.AreEqual(DragDropHelper.WorkflowItemTypeNameFormat, formats[0]);
            var name = typeof(FlowSwitch<string>).AssemblyQualifiedName;
            Assert.AreEqual(name, value.GetData(formats[0]));
        }