public void CreateWorkflow() { using (Utilities.Workflow.Manager.Manager TempOperation = new Utilities.Workflow.Manager.Manager(Utilities.IoC.Manager.Bootstrapper.Resolve <Utilities.IO.FileSystem.Manager>(), Utilities.IoC.Manager.Bootstrapper.Resolve <Utilities.IO.Serializers.Manager>())) { var Workflow = TempOperation.CreateWorkflow <dynamic>("ASDF"); Assert.NotNull(Workflow); Assert.Equal("ASDF", Workflow.Name); Assert.Equal(typeof(object), Workflow.DataType); } Assert.True(new System.IO.FileInfo(AppDomain.CurrentDomain.BaseDirectory + "/App_Data/Workflows.obj").Exists); }
public void CreateWorkflow() { using (Utilities.Workflow.Manager.Manager TempOperation = new Utilities.Workflow.Manager.Manager(Utilities.IoC.Manager.Bootstrapper.Resolve<Utilities.IO.FileSystem.Manager>(), Utilities.IoC.Manager.Bootstrapper.Resolve<Utilities.IO.Serializers.Manager>())) { var Workflow = TempOperation.CreateWorkflow<dynamic>("ASDF"); Assert.NotNull(Workflow); Assert.Equal("ASDF", Workflow.Name); Assert.Equal(typeof(object), Workflow.DataType); } Assert.True(new System.IO.FileInfo(AppDomain.CurrentDomain.BaseDirectory + "/App_Data/Workflows.obj").Exists); }
public void WorkflowExists() { using (Utilities.Workflow.Manager.Manager TempOperation = new Utilities.Workflow.Manager.Manager(Utilities.IoC.Manager.Bootstrapper.Resolve <Utilities.IO.FileSystem.Manager>(), Utilities.IoC.Manager.Bootstrapper.Resolve <Utilities.IO.Serializers.Manager>())) { var Workflow = TempOperation.CreateWorkflow <dynamic>("ASDF"); Assert.NotNull(Workflow); Assert.Equal("ASDF", Workflow.Name); Assert.Equal(typeof(object), Workflow.DataType); Assert.True(TempOperation.Exists("ASDF")); Assert.True(!TempOperation.Exists("ASDF2")); } }
public void GetWorkflow() { using (Utilities.Workflow.Manager.Manager TempOperation = new Utilities.Workflow.Manager.Manager(Utilities.IoC.Manager.Bootstrapper.Resolve<Utilities.IO.FileSystem.Manager>(), Utilities.IoC.Manager.Bootstrapper.Resolve<Utilities.IO.Serializers.Manager>())) { var Workflow = TempOperation.CreateWorkflow<dynamic>("ASDF"); Assert.NotNull(Workflow); Assert.Equal("ASDF", Workflow.Name); Assert.Equal(typeof(object), Workflow.DataType); Workflow = TempOperation["ASDF"] as IWorkflow<dynamic>; Assert.NotNull(Workflow); Assert.Equal("ASDF", Workflow.Name); Assert.Equal(typeof(object), Workflow.DataType); } }
public void GetWorkflow() { using (Utilities.Workflow.Manager.Manager TempOperation = new Utilities.Workflow.Manager.Manager(Utilities.IoC.Manager.Bootstrapper.Resolve <Utilities.IO.FileSystem.Manager>(), Utilities.IoC.Manager.Bootstrapper.Resolve <Utilities.IO.Serializers.Manager>())) { IWorkflow <dynamic> Workflow = TempOperation.CreateWorkflow <dynamic>("ASDF"); Assert.NotNull(Workflow); Assert.Equal("ASDF", Workflow.Name); Assert.Equal(typeof(object), Workflow.DataType); Workflow = TempOperation["ASDF"] as IWorkflow <dynamic>; Assert.NotNull(Workflow); Assert.Equal("ASDF", Workflow.Name); Assert.Equal(typeof(object), Workflow.DataType); } }
public void Serialization() { using (Utilities.Workflow.Manager.Manager TempOperation = new Utilities.Workflow.Manager.Manager(Utilities.IoC.Manager.Bootstrapper.Resolve<Utilities.IO.FileSystem.Manager>(), Utilities.IoC.Manager.Bootstrapper.Resolve<Utilities.IO.Serializers.Manager>())) { IWorkflow<dynamic> Workflow = TempOperation.CreateWorkflow<dynamic>("ASDF") .Do(x => x + 1) .Do(x => x + 1, new GenericConstraint<dynamic>(x => x > 0)); Assert.Equal("ASDF", Workflow.Name); Assert.Equal(typeof(object), Workflow.DataType); Assert.Equal(3, Workflow.Start(1)); } Assert.True(new System.IO.FileInfo(AppDomain.CurrentDomain.BaseDirectory + "/App_Data/Workflows.obj").Exists); using (Utilities.Workflow.Manager.Manager TempOperation = new Utilities.Workflow.Manager.Manager(Utilities.IoC.Manager.Bootstrapper.Resolve<Utilities.IO.FileSystem.Manager>(), Utilities.IoC.Manager.Bootstrapper.Resolve<Utilities.IO.Serializers.Manager>())) { IWorkflow<dynamic> Workflow = TempOperation.CreateWorkflow<dynamic>("ASDF"); Assert.Equal("ASDF", Workflow.Name); Assert.Equal(typeof(object), Workflow.DataType); Assert.Equal(3, Workflow.Start(1)); } }
public void Serialization() { using (Utilities.Workflow.Manager.Manager TempOperation = new Utilities.Workflow.Manager.Manager(Utilities.IoC.Manager.Bootstrapper.Resolve <Utilities.IO.FileSystem.Manager>(), Utilities.IoC.Manager.Bootstrapper.Resolve <Utilities.IO.Serializers.Manager>())) { var Workflow = TempOperation.CreateWorkflow <dynamic>("ASDF") .Do(x => x + 1) .Do(x => x + 1, new GenericConstraint <dynamic>(x => x > 0)); Assert.Equal("ASDF", Workflow.Name); Assert.Equal(typeof(object), Workflow.DataType); Assert.Equal(3, Workflow.Start(1)); } Assert.True(new System.IO.FileInfo(AppDomain.CurrentDomain.BaseDirectory + "/App_Data/Workflows.obj").Exists); using (Utilities.Workflow.Manager.Manager TempOperation = new Utilities.Workflow.Manager.Manager(Utilities.IoC.Manager.Bootstrapper.Resolve <Utilities.IO.FileSystem.Manager>(), Utilities.IoC.Manager.Bootstrapper.Resolve <Utilities.IO.Serializers.Manager>())) { var Workflow = TempOperation.CreateWorkflow <dynamic>("ASDF"); Assert.Equal("ASDF", Workflow.Name); Assert.Equal(typeof(object), Workflow.DataType); Assert.Equal(3, Workflow.Start(1)); } }
public void WorkflowExists() { using (Utilities.Workflow.Manager.Manager TempOperation = new Utilities.Workflow.Manager.Manager(Utilities.IoC.Manager.Bootstrapper.Resolve<Utilities.IO.FileSystem.Manager>(), Utilities.IoC.Manager.Bootstrapper.Resolve<Utilities.IO.Serializers.Manager>())) { IWorkflow<dynamic> Workflow = TempOperation.CreateWorkflow<dynamic>("ASDF"); Assert.NotNull(Workflow); Assert.Equal("ASDF", Workflow.Name); Assert.Equal(typeof(object), Workflow.DataType); Assert.True(TempOperation.Exists("ASDF")); Assert.True(!TempOperation.Exists("ASDF2")); } }