public void TestAddTask()
        {
            var configName = "TEST - " + DateTime.Now.ToString();
            WorkflowConfigurationService.Instance.CreateWorkflowConfiguration(configName, "Moriyama.Workflow.Domain.WorkflowConfiguration, Moriyama.Workflow.Domain");

            foreach (var config in WorkflowConfigurationService.Instance.ConfigurationRepository.List())
            {
                if (config.Name == configName)
                {
                    IWorkflowTask t = new DummyWorkflowTask();
                    var taskId = WorkflowConfigurationService.Instance.AddTask(config.Id, t.GetType().AssemblyQualifiedName, null);
                    
                    Console.WriteLine(taskId);

                    WorkflowConfigurationService.Instance.SaveChanges(config.Id);

                    var x = WorkflowConfigurationRepository.Instance.GetById(config.Id);
                    x = WorkflowConfigurationRepository.Instance.RestoreState(x);

                    var s = new JavaScriptSerializer().Serialize(x);
                    Console.WriteLine(s);

                    break;
                }
            }

        }
        public void TestSetTaskProperties()
        {
            var configName = "TEST - " + DateTime.Now.ToString();
            WorkflowConfigurationService.Instance.CreateWorkflowConfiguration(configName, "Moriyama.Workflow.Domain.WorkflowConfiguration, Moriyama.Workflow.Domain");

            foreach (var config in WorkflowConfigurationService.Instance.ConfigurationRepository.List())
            {
                if (config.Name == configName)
                {
                    IWorkflowTask t = new DummyWorkflowTask();
                    var taskId = WorkflowConfigurationService.Instance.AddTask(config.Id, t.GetType().AssemblyQualifiedName, null);

                    Console.WriteLine(taskId);

                    WorkflowConfigurationService.Instance.SaveChanges(config.Id);

                    var x = WorkflowConfigurationRepository.Instance.GetById(config.Id);
                    x = WorkflowConfigurationRepository.Instance.RestoreState(x);

                    var s = new JavaScriptSerializer().Serialize(x);
                    Console.WriteLine(s);

                    var props = new Dictionary<string, object>
                            {
                                {"Description", "Woohoo"}, 
                                {"Name", "Spooky"}
                            };

                    WorkflowConfigurationService.Instance.SetTaskProperties(config.Id, taskId, props);
                    WorkflowConfigurationService.Instance.SaveChanges(config.Id);

                    var y = WorkflowConfigurationRepository.Instance.GetById(config.Id);
                    y = WorkflowConfigurationRepository.Instance.RestoreState(y);

                    s = new JavaScriptSerializer().Serialize(y);
                    Console.WriteLine(s);


                    break;
                }

            }

        }