Commit Graph
1 Commits
Author SHA1 Message Date
Hector Ventura 6a74d7d2d5 test: cover Printer and the floci update flow (#57)
* test: cover Printer and the floci update flow

PrinterTest pins where text, errors and warnings go, what --quiet hides, and the JSON and YAML rendering. UpdateCommandTest drives floci update against a stub release server: a verified replacement, a checksum mismatch, --check, up to date, a Homebrew install and a non-version API response. UpdateCommand takes the binary path and the release URLs through a constructor for this, replacing a package-private field.

Signed-off-by: Hector Ventura <hectorvent@gmail.com>

* test: check the exact release files requested and the version check itself

The stub release server serves only the expected release's files, the replacement test asserts the two requests made, valid JSON without a usable version is covered, and the Printer assertions use the platform line separator.

Signed-off-by: Hector Ventura <hectorvent@gmail.com>

---------

Signed-off-by: Hector Ventura <hectorvent@gmail.com>
2026-10-10 22:30:07 -05:00