Skip to content

Commit

Permalink
Stash.
Browse files Browse the repository at this point in the history
  • Loading branch information
Corniel Nobel committed Jun 6, 2023
1 parent f985623 commit c6c0762
Show file tree
Hide file tree
Showing 13 changed files with 496 additions and 495 deletions.
227 changes: 0 additions & 227 deletions src/Qowaiv.DomainModel.TestTools/AggregateRootAssert.cs

This file was deleted.

46 changes: 0 additions & 46 deletions src/Qowaiv.DomainModel.TestTools/Assert.cs

This file was deleted.

37 changes: 0 additions & 37 deletions src/Qowaiv.DomainModel.TestTools/AssertionFailed.cs

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
using Qowaiv.DomainModel;
using Qowaiv.DomainModel.TestTools.FluentAssertions;
using System.Diagnostics.Contracts;

namespace FluentAssertions;

/// <summary>Contains extension methods for custom assertions in unit tests.</summary>
[DebuggerNonUserCode]
public static class QowaivDomainModelFluentAssertions
{
/// <summary>
/// Returns an <see cref="AggregateAssertions{TAggregate, TId}"/> object that can be used to assert the
/// current aggregate.
/// </summary>
/// <typeparam name="TAggregate">
/// The type of the aggregate.
/// </typeparam>
/// <typeparam name="TId">
/// The type of the identifier of the aggregate.
/// </typeparam>
[Pure]
[CLSCompliant(false)]
public static AggregateAssertions<TAggregate, TId> Should<TAggregate, TId>(this TAggregate? aggregate)
where TAggregate : AggregateRoot<TAggregate, TId>, new() => new(aggregate);

/// <summary>
/// Returns an <see cref="EventBufferAssertions{TId}"/> object that can be used to assert the
/// current event buffer.
/// </summary>
/// <typeparam name="TId">
/// The type of the identifier of the event buffer.
/// </typeparam>
[Pure]
[CLSCompliant(false)]
public static EventBufferAssertions<TId> Should<TId>(this EventBuffer<TId> buffer) => new(buffer);
}
Loading

0 comments on commit c6c0762

Please sign in to comment.