Development
Coming soon. This page will document the local development workflow: building, testing, regenerating FlatBuffers code, and running benchmarks.
Build
# Build the entire solution
dotnet build Virtufin.slnx
# Build in Release mode
dotnet build Virtufin.slnx -c Release
# Build a single project
dotnet build src/Virtufin.Core/Virtufin.Core.csproj
Test
# Run all tests
dotnet test Virtufin.slnx
# Run a single test project
dotnet test tests/Virtufin.Core.Test/Virtufin.Core.Test.csproj
dotnet test tests/Virtufin.Data.Test/Virtufin.Data.Test.csproj
# Run a single test by fully-qualified name
dotnet test tests/Virtufin.Core.Test/Virtufin.Core.Test.csproj \
--filter "FullyQualifiedName=Virtufin.Core.Test.RegistryTest.TestValues"
# Run tests matching a display name pattern
dotnet test Virtufin.slnx --filter "DisplayName~Registry"
# With code coverage (Cobertura format)
dotnet test Virtufin.slnx --collect:"XPlat Code Coverage"
Test framework: xUnit 2.9.3 with FluentAssertions 8.8.0. Always use FluentAssertions style:
value.Should().Be(expected);
result.Should().BeNull();
list.Should().BeEquivalentTo(expected);
Regenerate FlatBuffers code
The variant.fbs, cloud_event.fbs, and worker_response.fbs schemas live in src/Virtufin.Data/Schemas/. The C# code is generated into src/Virtufin.Data/Generated/ (gitignored).
# From the repo root
flatc --csharp -o src/Virtufin.Data/Generated \
src/Virtufin.Data/Schemas/variant.fbs
You need flatc installed locally. On macOS: brew install flatbuffers.
Regenerate proto stubs
If the C# protobuf stubs in src/Virtufin.Data/Protos/Generated/ (or similar) are stale, run buf generate (per repo convention).
CI
- Build + test on push to
master(and PRs): runs the full test suite. - Docs lint on
workflow_dispatch: validates that all public types have XML doc comments. - Docs deploy on push to
master(ifdocs/**changed): builds MkDocs, deploys tolib.docs.virtufin.com.
Conventions
See Architecture for the project file conventions and C# style guide.
See also
- Architecture — project structure and dependency direction
- FlatBuffers — schema and codegen
- Core EAV — for examples of the EAV types