Add XML docs required by CommentChecker fixes
All checks were successful
NuGet Package Publish / nuget (push) Successful in 1m13s

This commit is contained in:
Joseph Doherty
2026-02-23 04:39:25 -05:00
parent cce24fa8f3
commit 6c4714f666
15 changed files with 444 additions and 15 deletions

View File

@@ -6,6 +6,9 @@ namespace ZB.MOM.WW.CBDDC.Sample.Console.Tests;
public abstract class OplogStoreContractTestBase
{
/// <summary>
/// Verifies append, merge, and drop behavior across query, chain, and restart scenarios.
/// </summary>
[Fact]
public async Task OplogStore_AppendQueryMergeDrop_AndLastHash_Works()
{
@@ -46,6 +49,9 @@ public abstract class OplogStoreContractTestBase
(await rehydratedStore.ExportAsync()).ShouldBeEmpty();
}
/// <summary>
/// Verifies dataset isolation between primary and secondary stores.
/// </summary>
[Fact]
public async Task OplogStore_DatasetIsolation_Works()
{
@@ -68,6 +74,9 @@ public abstract class OplogStoreContractTestBase
logs[0].DatasetId.ShouldBe(DatasetId.Logs);
}
/// <summary>
/// Verifies chain range queries return ordered linked entries.
/// </summary>
[Fact]
public async Task OplogStore_GetChainRangeAsync_ReturnsOrderedLinkedRange()
{
@@ -89,8 +98,20 @@ public abstract class OplogStoreContractTestBase
range[1].Hash.ShouldBe(entry3.Hash);
}
/// <summary>
/// Creates the contract harness for this test class.
/// </summary>
protected abstract Task<IOplogStoreContractHarness> CreateHarnessAsync();
/// <summary>
/// Creates a reusable oplog entry with deterministic timestamps.
/// </summary>
/// <param name="collection">The collection name.</param>
/// <param name="key">The entry key.</param>
/// <param name="nodeId">The node identifier generating the entry.</param>
/// <param name="wall">The wall-clock component of the HLC timestamp.</param>
/// <param name="logic">The logical clock component of the HLC timestamp.</param>
/// <param name="previousHash">The previous entry hash.</param>
protected static OplogEntry CreateOplogEntry(
string collection,
string key,
@@ -111,11 +132,28 @@ public abstract class OplogStoreContractTestBase
public interface IOplogStoreContractHarness : IAsyncDisposable
{
/// <summary>
/// Gets the active contract store.
/// </summary>
IOplogStore Store { get; }
/// <summary>
/// Reopens the harness storage.
/// </summary>
IOplogStore ReopenStore();
/// <summary>
/// Appends an entry for the specified dataset.
/// </summary>
/// <param name="entry">The oplog entry to append.</param>
/// <param name="datasetId">The dataset identifier.</param>
/// <param name="cancellationToken">The cancellation token.</param>
Task AppendOplogEntryAsync(OplogEntry entry, string datasetId, CancellationToken cancellationToken = default);
/// <summary>
/// Exports entries for the specified dataset.
/// </summary>
/// <param name="datasetId">The dataset identifier.</param>
/// <param name="cancellationToken">The cancellation token.</param>
Task<IEnumerable<OplogEntry>> ExportAsync(string datasetId, CancellationToken cancellationToken = default);
}