27 lines
642 B
C#
27 lines
642 B
C#
using LCU.API.Internal.DocumentLib.Containers;
|
|
|
|
namespace OwnerNumberMigrationTest.TestDoubles;
|
|
|
|
public class FakeMigrationObserver : IObserver<DocumentInformation>
|
|
{
|
|
public List<(DocumentInformation doc, DateTime started)> Documents { get; } = new();
|
|
|
|
public List<Exception> Errors { get; } = new();
|
|
|
|
public List<DateTime> Completions { get; } = new();
|
|
|
|
public void OnCompleted()
|
|
{
|
|
Completions.Add(DateTime.Now);
|
|
}
|
|
|
|
public void OnError(Exception error)
|
|
{
|
|
Errors.Add(error);
|
|
}
|
|
|
|
public void OnNext(DocumentInformation value)
|
|
{
|
|
Documents.Add((value, DateTime.Now));
|
|
}
|
|
} |