Build and Test
Information for developers working on ImgForge.
dotnet build
Run unit tests without integration tests (no browser required):
dotnet test --filter "Category!=Integration"
Run all tests including integration tests:
dotnet test
Chromium is downloaded automatically on the first run of integration tests — no separate install step needed.
| Package | Role |
|---|---|
| Scriban | Liquid-syntax template engine — substitutes {{ title }}, {{ bg }}, {{ width }}, {{ height }}, and {% for img in overlays %} in HTML templates |
| PuppeteerSharp | Headless Chromium driver — renders the HTML with full CSS support and captures a pixel-perfect screenshot. Chromium is downloaded automatically on first run. |
| System.CommandLine | Parses CLI arguments and subcommands |
| SixLabors.ImageSharp | Used in tests to verify output PNG dimensions |
| xunit | Test framework |
After building, you can install your local build as a global tool:
dotnet pack
dotnet tool install --global --add-source ./nupkg ImgForge
Or update an existing installation:
dotnet pack
dotnet tool update --global --add-source ./nupkg ImgForge