Tests: Add fixtures

This commit is contained in:
theresa 2022-04-01 16:24:45 +02:00
parent a61470dfc7
commit 5d16c5b530
2 changed files with 93 additions and 1 deletions

View file

@ -1898,7 +1898,7 @@ var PhotoFixtures = PhotoMap{
Albums: []Album{},
Files: []File{},
Labels: []PhotoLabel{
LabelFixtures.PhotoLabel(1000029, "%tennis", 20, "image"),
LabelFixtures.PhotoLabel(10000029, "%tennis", 20, "image"),
},
CreatedAt: time.Date(2021, 1, 1, 0, 0, 0, 0, time.UTC),
UpdatedAt: time.Date(2021, 1, 1, 0, 0, 0, 0, time.UTC),

View file

@ -35,6 +35,98 @@ var PhotoKeywordFixtures = PhotoKeywordMap{
PhotoID: 1000030,
KeywordID: 1000007,
},
"9": {
PhotoID: 10000029,
KeywordID: 10000005,
},
"10": {
PhotoID: 1000031,
KeywordID: 10000006,
},
"11": {
PhotoID: 1000032,
KeywordID: 10000008,
},
"12": {
PhotoID: 1000033,
KeywordID: 10000009,
},
"13": {
PhotoID: 1000034,
KeywordID: 10000010,
},
"14": {
PhotoID: 1000035,
KeywordID: 10000011,
},
"15": {
PhotoID: 1000036,
KeywordID: 10000012,
},
"16": {
PhotoID: 1000037,
KeywordID: 10000013,
},
"17": {
PhotoID: 1000038,
KeywordID: 10000014,
},
"18": {
PhotoID: 1000039,
KeywordID: 10000015,
},
"19": {
PhotoID: 1000040,
KeywordID: 10000016,
},
"20": {
PhotoID: 1000041,
KeywordID: 10000017,
},
"21": {
PhotoID: 1000042,
KeywordID: 10000018,
},
"22": {
PhotoID: 1000043,
KeywordID: 10000019,
},
"23": {
PhotoID: 1000044,
KeywordID: 10000020,
},
"24": {
PhotoID: 1000045,
KeywordID: 10000021,
},
"25": {
PhotoID: 1000046,
KeywordID: 10000022,
},
"26": {
PhotoID: 1000047,
KeywordID: 10000023,
},
"27": {
PhotoID: 1000048,
KeywordID: 10000024,
},
"28": {
PhotoID: 1000049,
KeywordID: 10000025,
},
"29": {
PhotoID: 1000045,
KeywordID: 10000018,
},
"30": {
PhotoID: 1000045,
KeywordID: 10000018,
},
"31": {
PhotoID: 1000036,
KeywordID: 10000015,
},
}
// CreatePhotoKeywordFixtures inserts known entities into the database for testing.