public static void DeleteCategory(string categoryId)
        {
            using (new SampleMethodScope())
            {
                var getCategoryResult = Proxy.GetValue(EngineExtensions.AuthoringContainer.Value.Categories.ByKey(categoryId));
                getCategoryResult.Should().NotBeNull();

                var selectDeleteOptionView = Proxy.GetValue(EngineExtensions.AuthoringContainer.Value.GetEntityView(categoryId, "Details", "SelectCategoryDeleteOption", categoryId));
                selectDeleteOptionView.Properties = new ObservableCollection <ViewProperty>
                {
                    new ViewProperty {
                        Name = "Version", Value = getCategoryResult.Version.ToString(), OriginalType = "System.Int32"
                    },
                };

                var selectDeleteOptionResult = Proxy.DoCommand(EngineExtensions.AuthoringContainer.Value.DoAction(selectDeleteOptionView));
                selectDeleteOptionResult.Messages.Should().NotContainErrors();

                var view = Proxy.GetValue(EngineExtensions.AuthoringContainer.Value.GetEntityView(getCategoryResult.Id, "Details", "DeleteCategory", getCategoryResult.Id));
                view.Properties = new ObservableCollection <ViewProperty>
                {
                    new ViewProperty {
                        Name = "Version", Value = (getCategoryResult.Version + 1).ToString(), OriginalType = "System.Int32"
                    },
                };

                var result = Proxy.DoCommand(EngineExtensions.AuthoringContainer.Value.DoAction(view));
                result.Messages.Should().NotContainErrors();

                RunPurgeCategoriesMinion();

                getCategoryResult = Proxy.GetValue(EngineExtensions.AuthoringContainer.Value.Categories.ByKey(categoryId));
                // fix for odata - Fluent assertions causes an Odata exception when a null check fails.
                (getCategoryResult == null).Should().BeTrue($"The category {categoryId} was not deleted");
                ConsoleExtensions.WriteExpectedError();
            }
        }
 public SampleScenarioScope(string scenarioName)
 {
     _scenarioName = scenarioName;
     _watch.Start();
     ConsoleExtensions.WriteColoredLine(ConsoleColor.White, $"[Begin Scenario] {_scenarioName}");
 }