Verify Calendar credits in the integrated app shell
2 files changed,
+22
−1
implementation/open-source-credits/proposal.json+1 −1internal/calendar/credits_test.go+21 −0
CI passed — run details
diff --git a/implementation/open-source-credits/proposal.json b/implementation/open-source-credits/proposal.json| index 181bcd5..7f8b5ef 100644 |
| --- a/implementation/open-source-credits/proposal.json |
| +++ b/implementation/open-source-credits/proposal.json |
| @@ -3,5 +3,5 @@ |
| "request": "Attribute the suite's open-source dependencies, extracting reusable Estilo components. Copy review waived for this round.", |
| "reuse": "Second actual consumer of Estilo credits at f5fa112, after Home. Same /help/open-source URL, source notices, renderer and CSS. Calendar retains its own shell; Help appears for signed-in app pages and on credits, preserving anonymous booking/sign-in journeys.", |
| "inventory": "Production linux/arm64 pure-Go dependencies, compiler LICENSE, package/root/bundled notices and explicit Lucide/Feather attribution. Exact first-party Oficina modules excluded; pinned Keymail signin has no licence file and stays recorded as missing, without inventing one. package.json is browser-test tooling only, not an app runtime bundle.", |
| - "verification": "Public route, no authentication/cookie mint, no-store/referrer boundaries, CSS route, notice presence and production dependency drift tests pass. Full make ci passed before integration. Final integration with split-series repair569fe4b and final gate/CI/Fable review pending. No merge or deployment." |
| + "verification": "Full integrated make ci passed with split-series repair569fe4b. Public route/no-cookie/no-store/referrer/CSS/notice tests and production dependency drift check passed. Exact rendered Calendar page passed Chromium320/1200px overflow,24px targets and keyboard Enter while scripting was disabled. Final exact CI and Fable review pending; no merge/deployment." |
| } |
diff --git a/internal/calendar/credits_test.go b/internal/calendar/credits_test.go| index 2b23a6f..0e380bf 100644 |
| --- a/internal/calendar/credits_test.go |
| +++ b/internal/calendar/credits_test.go |
| @@ -4,6 +4,9 @@ import ( |
| "encoding/json" |
| "net/http" |
| "net/http/httptest" |
| + "os" |
| + "path/filepath" |
| + "regexp" |
| "strings" |
| "testing" |
| ) |
| @@ -28,6 +31,24 @@ func TestCreditsArePublicAndContainDependencyNotices(t *testing.T) { |
| if style.Code != http.StatusOK || !strings.HasPrefix(style.Header().Get("Content-Type"), "text/css") || !strings.Contains(style.Body.String(), "[estilo-credits]") { |
| t.Fatal("shared credit styles not served") |
| } |
| + if output := os.Getenv("CALENDAR_CREDITS_EVIDENCE_DIR"); output != "" { |
| + if err := os.MkdirAll(output, 0700); err != nil { |
| + t.Fatal(err) |
| + } |
| + if err := os.WriteFile(filepath.Join(output, "page.html"), response.Body.Bytes(), 0600); err != nil { |
| + t.Fatal(err) |
| + } |
| + for _, match := range regexp.MustCompile(`(?:href|src)="(/static/[^" ]+)"`).FindAllStringSubmatch(response.Body.String(), -1) { |
| + asset := httptest.NewRecorder() |
| + app.Handler().ServeHTTP(asset, httptest.NewRequest(http.MethodGet, match[1], nil)) |
| + if asset.Code != http.StatusOK { |
| + t.Fatal("credits fixture asset unavailable", match[1]) |
| + } |
| + if err := os.WriteFile(filepath.Join(output, filepath.Base(match[1])), asset.Body.Bytes(), 0600); err != nil { |
| + t.Fatal(err) |
| + } |
| + } |
| + } |
| var inventory creditInventory |
| if err := json.Unmarshal(creditNotices, &inventory); err != nil { |
| t.Fatal(err) |