internal/pkg: optionally named static file
All checks were successful
Test / Create distribution (push) Successful in 47s
Test / Sandbox (race detector) (push) Successful in 8m9s
Test / ShareFS (push) Successful in 8m30s
Test / Hakurei (race detector) (push) Successful in 10m35s
Test / Hakurei (push) Successful in 3m58s
Test / Sandbox (push) Successful in 1m42s
Test / Hpkg (push) Successful in 3m57s
Test / Flake checks (push) Successful in 1m46s

These are generally for generating configuration files or build scripts, naming them is quite useful.

Signed-off-by: Ophestra <cat@gensokyo.uk>
This commit is contained in:
2026-01-12 04:34:50 +09:00
parent 29951c5174
commit 610572d0e6
3 changed files with 23 additions and 4 deletions

View File

@@ -496,7 +496,7 @@ func TestCache(t *testing.T) {
if _, _, err = c.Cure(stubArtifactF{
kind: pkg.KindExec,
params: []byte("unreachable artifact cured after cancel"),
deps: []pkg.Artifact{pkg.NewFile([]byte("unreachable dependency"))},
deps: []pkg.Artifact{pkg.NewFile("", []byte("unreachable dependency"))},
}); !reflect.DeepEqual(err, context.Canceled) {
t.Fatalf("(closed) Cure: error = %v", err)
}