Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
using System.Linq;
using JasperFx.Core;
using JasperFx.Core.Reflection;
using Marten.Events.TestSupport;
using JasperFx.Events.TestSupport;
using Marten.Exceptions;
using Shouldly;
using Xunit;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
using JasperFx.Events.Projections;
using Marten;
using Marten.Events.Projections;
using JasperFx.Events.TestSupport;
using Marten.Events.TestSupport;
using Marten.Storage;
using Marten.Testing.Documents;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
using System.Linq;
using System.Threading.Tasks;
using JasperFx.Events.Projections;
using JasperFx.Events.TestSupport;
using Marten.Events.TestSupport;
using Marten.Testing.Documents;
using Marten.Testing.Harness;
Expand Down Expand Up @@ -94,13 +95,13 @@ public async Task a_scenario_cannot_be_executed_twice()
var scenario = new ProjectionScenario(theStore);
scenario.Append(Guid.NewGuid(), new CreateUser { UserId = Guid.NewGuid(), UserName = "Once" });

await scenario.Execute(TestContext.Current.CancellationToken);
await scenario.ExecuteAsync(TestContext.Current.CancellationToken);

// The steps were consumed by the first run, so a second run would be a silent no-op.
// It should be a loud failure instead.
await Should.ThrowAsync<InvalidOperationException>(async () =>
{
await scenario.Execute(TestContext.Current.CancellationToken);
await scenario.ExecuteAsync(TestContext.Current.CancellationToken);
});
}

Expand Down
2 changes: 1 addition & 1 deletion src/Marten/AdvancedOperations.cs
Original file line number Diff line number Diff line change
Expand Up @@ -299,7 +299,7 @@ public Task EventProjectionScenario(Action<ProjectionScenario> configuration, Ca
var scenario = new ProjectionScenario(_store);
configuration(scenario);

return scenario.Execute(ct);
return scenario.ExecuteAsync(ct);
}

/// <summary>
Expand Down
133 changes: 0 additions & 133 deletions src/Marten/Events/TestSupport/ProjectionScenario.Assertions.cs

This file was deleted.

Loading
Loading