Backend: Add fixtures for photokeywords
This commit is contained in:
parent
5d2c4fa5d6
commit
409cea4659
1 changed files with 15 additions and 0 deletions
15
internal/entity/photo_keyword_fixtures.go
Normal file
15
internal/entity/photo_keyword_fixtures.go
Normal file
|
@ -0,0 +1,15 @@
|
|||
package entity
|
||||
|
||||
var PhotoKeywordFixtures = map[string]PhotoKeyword{
|
||||
"1": {
|
||||
PhotoID: 1000004,
|
||||
KeywordID: 1000000,
|
||||
},
|
||||
}
|
||||
|
||||
// CreatePhotoKeywordFixtures inserts known entities into the database for testing.
|
||||
func CreatePhotoKeywordFixtures() {
|
||||
for _, entity := range PhotoKeywordFixtures {
|
||||
Db().Create(&entity)
|
||||
}
|
||||
}
|
Loading…
Reference in a new issue