Fix audit findings for coverage, architecture checks, and XML docs
All checks were successful
NuGet Publish / build-and-pack (push) Successful in 45s
NuGet Publish / publish-to-gitea (push) Successful in 52s

This commit is contained in:
Joseph Doherty
2026-02-20 15:43:25 -05:00
parent 5528806518
commit 3ffd468c79
99 changed files with 23746 additions and 9548 deletions

View File

@@ -11,6 +11,9 @@ public class QueryPrimitivesTests : IDisposable
private readonly StorageEngine _storage;
private readonly BTreeIndex _index;
/// <summary>
/// Initializes a new instance of the <see cref="QueryPrimitivesTests"/> class.
/// </summary>
public QueryPrimitivesTests()
{
_testFile = Path.Combine(Path.GetTempPath(), $"docdb_test_{Guid.NewGuid()}.db");
@@ -55,6 +58,9 @@ public class QueryPrimitivesTests : IDisposable
_index.Insert(key, new DocumentLocation(1, 1), txnId);
}
/// <summary>
/// Executes Equal_ShouldFindExactMatch.
/// </summary>
[Fact]
public void Equal_ShouldFindExactMatch()
{
@@ -65,6 +71,9 @@ public class QueryPrimitivesTests : IDisposable
result[0].Key.ShouldBe(key);
}
/// <summary>
/// Executes Equal_ShouldReturnEmpty_WhenNotFound.
/// </summary>
[Fact]
public void Equal_ShouldReturnEmpty_WhenNotFound()
{
@@ -74,6 +83,9 @@ public class QueryPrimitivesTests : IDisposable
result.ShouldBeEmpty();
}
/// <summary>
/// Executes GreaterThan_ShouldReturnMatches.
/// </summary>
[Fact]
public void GreaterThan_ShouldReturnMatches()
{
@@ -85,6 +97,9 @@ public class QueryPrimitivesTests : IDisposable
result[1].Key.ShouldBe(IndexKey.Create(50));
}
/// <summary>
/// Executes GreaterThanOrEqual_ShouldReturnMatches.
/// </summary>
[Fact]
public void GreaterThanOrEqual_ShouldReturnMatches()
{
@@ -97,6 +112,9 @@ public class QueryPrimitivesTests : IDisposable
result[2].Key.ShouldBe(IndexKey.Create(50));
}
/// <summary>
/// Executes LessThan_ShouldReturnMatches.
/// </summary>
[Fact]
public void LessThan_ShouldReturnMatches()
{
@@ -110,6 +128,9 @@ public class QueryPrimitivesTests : IDisposable
result[1].Key.ShouldBe(IndexKey.Create(10));
}
/// <summary>
/// Executes Between_ShouldReturnRange.
/// </summary>
[Fact]
public void Between_ShouldReturnRange()
{
@@ -123,6 +144,9 @@ public class QueryPrimitivesTests : IDisposable
result[2].Key.ShouldBe(IndexKey.Create(40));
}
/// <summary>
/// Executes StartsWith_ShouldReturnPrefixMatches.
/// </summary>
[Fact]
public void StartsWith_ShouldReturnPrefixMatches()
{
@@ -133,6 +157,9 @@ public class QueryPrimitivesTests : IDisposable
result[1].Key.ShouldBe(IndexKey.Create("ABC"));
}
/// <summary>
/// Executes Like_ShouldSupportWildcards.
/// </summary>
[Fact]
public void Like_ShouldSupportWildcards()
{
@@ -148,6 +175,9 @@ public class QueryPrimitivesTests : IDisposable
// AB ok. ABC ok. B ok.
}
/// <summary>
/// Executes Like_Underscore_ShouldMatchSingleChar.
/// </summary>
[Fact]
public void Like_Underscore_ShouldMatchSingleChar()
{
@@ -157,6 +187,9 @@ public class QueryPrimitivesTests : IDisposable
result[0].Key.ShouldBe(IndexKey.Create("AB"));
}
/// <summary>
/// Executes In_ShouldReturnSpecificKeys.
/// </summary>
[Fact]
public void In_ShouldReturnSpecificKeys()
{
@@ -169,6 +202,9 @@ public class QueryPrimitivesTests : IDisposable
result[2].Key.ShouldBe(IndexKey.Create(50));
}
/// <summary>
/// Executes Dispose.
/// </summary>
public void Dispose()
{
_storage.Dispose();