mirror of
https://tangled.org/evan.jarrett.net/at-container-registry
synced 2026-08-29 04:06:58 +00:00
fix unit tests
This commit is contained in:
@@ -38,6 +38,7 @@ func setupTestDB(t *testing.T) *sql.DB {
|
||||
media_type TEXT NOT NULL,
|
||||
config_digest TEXT,
|
||||
config_size INTEGER,
|
||||
artifact_type TEXT NOT NULL DEFAULT 'container-image',
|
||||
created_at TIMESTAMP NOT NULL,
|
||||
UNIQUE(did, repository, digest)
|
||||
);
|
||||
|
||||
+16
-14
@@ -571,21 +571,23 @@ func TestTemplateExecution_RepoCard(t *testing.T) {
|
||||
|
||||
// Sample data for repo-card template
|
||||
data := struct {
|
||||
OwnerHandle string
|
||||
Repository string
|
||||
IconURL string
|
||||
Description string
|
||||
StarCount int
|
||||
PullCount int
|
||||
IsStarred bool
|
||||
OwnerHandle string
|
||||
Repository string
|
||||
IconURL string
|
||||
Description string
|
||||
StarCount int
|
||||
PullCount int
|
||||
IsStarred bool
|
||||
ArtifactType string
|
||||
}{
|
||||
OwnerHandle: "alice.bsky.social",
|
||||
Repository: "myapp",
|
||||
IconURL: "",
|
||||
Description: "A cool container image",
|
||||
StarCount: 42,
|
||||
PullCount: 1337,
|
||||
IsStarred: true,
|
||||
OwnerHandle: "alice.bsky.social",
|
||||
Repository: "myapp",
|
||||
IconURL: "",
|
||||
Description: "A cool container image",
|
||||
StarCount: 42,
|
||||
PullCount: 1337,
|
||||
IsStarred: true,
|
||||
ArtifactType: "container-image",
|
||||
}
|
||||
|
||||
buf := new(bytes.Buffer)
|
||||
|
||||
Reference in New Issue
Block a user