elsa-core/test/integration/Elsa.Core.IntegrationTests/IfElseWorkflowTests.cs

25 lines
763 B
C#
Raw Normal View History

2020-10-23 11:20:22 +00:00
using System.Linq;
using System.Threading.Tasks;
using Elsa.Core.IntegrationTests.Workflows;
using Elsa.Testing.Shared.Helpers;
using Xunit;
using Xunit.Abstractions;
namespace Elsa.Core.IntegrationTests
{
public class IfElseWorkflowTests : WorkflowsUnitTestBase
{
public IfElseWorkflowTests(ITestOutputHelper testOutputHelper) : base(testOutputHelper)
{
}
[Fact(DisplayName = "Runs IfElse twice")]
public async Task Test01()
{
var workflowInstance = await WorkflowRunner.RunWorkflowAsync<IfElseWorkflow>();
var iterationLogs = workflowInstance.ExecutionLog.Where(x => x.ActivityId == "IfElse").ToList();
Assert.Equal(2, iterationLogs.Count);
}
}
}