Tests: Add album fixtures
This commit is contained in:
parent
ff170ae7ed
commit
3ff00c65c5
2 changed files with 216 additions and 0 deletions
|
@ -293,6 +293,156 @@ var AlbumFixtures = AlbumMap{
|
|||
UpdatedAt: time.Date(2020, 2, 1, 0, 0, 0, 0, time.UTC),
|
||||
DeletedAt: nil,
|
||||
},
|
||||
"&ilikefood": {
|
||||
ID: 1000011,
|
||||
AlbumUID: "at1lxuqipotaab19",
|
||||
AlbumSlug: "&ilikefood",
|
||||
AlbumPath: "",
|
||||
AlbumType: AlbumDefault,
|
||||
AlbumTitle: "&IlikeFood",
|
||||
AlbumLocation: "",
|
||||
AlbumCategory: "",
|
||||
AlbumCaption: "",
|
||||
AlbumDescription: "",
|
||||
AlbumNotes: "",
|
||||
AlbumFilter: "",
|
||||
AlbumOrder: "name",
|
||||
AlbumTemplate: "",
|
||||
AlbumCountry: "zz",
|
||||
AlbumYear: 0,
|
||||
AlbumMonth: 0,
|
||||
AlbumDay: 0,
|
||||
AlbumFavorite: false,
|
||||
AlbumPrivate: false,
|
||||
CreatedAt: time.Date(2020, 1, 1, 0, 0, 0, 0, time.UTC),
|
||||
UpdatedAt: time.Date(2020, 2, 1, 0, 0, 0, 0, time.UTC),
|
||||
DeletedAt: nil,
|
||||
},
|
||||
"i-love-%-dog": {
|
||||
ID: 1000012,
|
||||
AlbumUID: "at1lxuqipotaab20",
|
||||
AlbumSlug: "i-love-%-dog",
|
||||
AlbumPath: "",
|
||||
AlbumType: AlbumDefault,
|
||||
AlbumTitle: "I love % dog",
|
||||
AlbumLocation: "",
|
||||
AlbumCategory: "",
|
||||
AlbumCaption: "",
|
||||
AlbumDescription: "",
|
||||
AlbumNotes: "",
|
||||
AlbumFilter: "",
|
||||
AlbumOrder: "name",
|
||||
AlbumTemplate: "",
|
||||
AlbumCountry: "zz",
|
||||
AlbumYear: 0,
|
||||
AlbumMonth: 0,
|
||||
AlbumDay: 0,
|
||||
AlbumFavorite: false,
|
||||
AlbumPrivate: false,
|
||||
CreatedAt: time.Date(2020, 1, 1, 0, 0, 0, 0, time.UTC),
|
||||
UpdatedAt: time.Date(2020, 2, 1, 0, 0, 0, 0, time.UTC),
|
||||
DeletedAt: nil,
|
||||
},
|
||||
"%gold": {
|
||||
ID: 1000013,
|
||||
AlbumUID: "at1lxuqipotaab21",
|
||||
AlbumSlug: "%gold",
|
||||
AlbumPath: "",
|
||||
AlbumType: AlbumDefault,
|
||||
AlbumTitle: "%gold",
|
||||
AlbumLocation: "",
|
||||
AlbumCategory: "",
|
||||
AlbumCaption: "",
|
||||
AlbumDescription: "",
|
||||
AlbumNotes: "",
|
||||
AlbumFilter: "",
|
||||
AlbumOrder: "name",
|
||||
AlbumTemplate: "",
|
||||
AlbumCountry: "zz",
|
||||
AlbumYear: 0,
|
||||
AlbumMonth: 0,
|
||||
AlbumDay: 0,
|
||||
AlbumFavorite: false,
|
||||
AlbumPrivate: false,
|
||||
CreatedAt: time.Date(2020, 1, 1, 0, 0, 0, 0, time.UTC),
|
||||
UpdatedAt: time.Date(2020, 2, 1, 0, 0, 0, 0, time.UTC),
|
||||
DeletedAt: nil,
|
||||
},
|
||||
"sale%": {
|
||||
ID: 1000014,
|
||||
AlbumUID: "at1lxuqipotaab22",
|
||||
AlbumSlug: "sale%",
|
||||
AlbumPath: "",
|
||||
AlbumType: AlbumDefault,
|
||||
AlbumTitle: "sale%",
|
||||
AlbumLocation: "",
|
||||
AlbumCategory: "",
|
||||
AlbumCaption: "",
|
||||
AlbumDescription: "",
|
||||
AlbumNotes: "",
|
||||
AlbumFilter: "",
|
||||
AlbumOrder: "name",
|
||||
AlbumTemplate: "",
|
||||
AlbumCountry: "zz",
|
||||
AlbumYear: 0,
|
||||
AlbumMonth: 0,
|
||||
AlbumDay: 0,
|
||||
AlbumFavorite: false,
|
||||
AlbumPrivate: false,
|
||||
CreatedAt: time.Date(2020, 1, 1, 0, 0, 0, 0, time.UTC),
|
||||
UpdatedAt: time.Date(2020, 2, 1, 0, 0, 0, 0, time.UTC),
|
||||
DeletedAt: nil,
|
||||
},
|
||||
"pets&dogs": {
|
||||
ID: 1000015,
|
||||
AlbumUID: "at1lxuqipotaab23",
|
||||
AlbumSlug: "pest&dogs",
|
||||
AlbumPath: "",
|
||||
AlbumType: AlbumDefault,
|
||||
AlbumTitle: "Pets & Dogs",
|
||||
AlbumLocation: "",
|
||||
AlbumCategory: "",
|
||||
AlbumCaption: "",
|
||||
AlbumDescription: "",
|
||||
AlbumNotes: "",
|
||||
AlbumFilter: "",
|
||||
AlbumOrder: "name",
|
||||
AlbumTemplate: "",
|
||||
AlbumCountry: "zz",
|
||||
AlbumYear: 0,
|
||||
AlbumMonth: 0,
|
||||
AlbumDay: 0,
|
||||
AlbumFavorite: false,
|
||||
AlbumPrivate: false,
|
||||
CreatedAt: time.Date(2020, 1, 1, 0, 0, 0, 0, time.UTC),
|
||||
UpdatedAt: time.Date(2020, 2, 1, 0, 0, 0, 0, time.UTC),
|
||||
DeletedAt: nil,
|
||||
},
|
||||
"light&": {
|
||||
ID: 1000016,
|
||||
AlbumUID: "at1lxuqipotaab24",
|
||||
AlbumSlug: "light&",
|
||||
AlbumPath: "",
|
||||
AlbumType: AlbumDefault,
|
||||
AlbumTitle: "Light&",
|
||||
AlbumLocation: "",
|
||||
AlbumCategory: "",
|
||||
AlbumCaption: "",
|
||||
AlbumDescription: "",
|
||||
AlbumNotes: "",
|
||||
AlbumFilter: "",
|
||||
AlbumOrder: "name",
|
||||
AlbumTemplate: "",
|
||||
AlbumCountry: "zz",
|
||||
AlbumYear: 0,
|
||||
AlbumMonth: 0,
|
||||
AlbumDay: 0,
|
||||
AlbumFavorite: false,
|
||||
AlbumPrivate: false,
|
||||
CreatedAt: time.Date(2020, 1, 1, 0, 0, 0, 0, time.UTC),
|
||||
UpdatedAt: time.Date(2020, 2, 1, 0, 0, 0, 0, time.UTC),
|
||||
DeletedAt: nil,
|
||||
},
|
||||
}
|
||||
|
||||
// CreateAlbumFixtures inserts known entities into the database for testing.
|
||||
|
|
|
@ -109,6 +109,72 @@ var PhotoAlbumFixtures = PhotoAlbumMap{
|
|||
Photo: PhotoFixtures.Pointer("Photo14"),
|
||||
Album: AlbumFixtures.Pointer("berlin-2019"),
|
||||
},
|
||||
"9": {
|
||||
PhotoUID: "pt9jtdre2lvl0yh0",
|
||||
AlbumUID: "at1lxuqipotaab24",
|
||||
Hidden: false,
|
||||
Missing: false,
|
||||
Order: 0,
|
||||
CreatedAt: time.Date(2020, 2, 6, 2, 6, 51, 0, time.UTC),
|
||||
UpdatedAt: time.Date(2020, 4, 28, 14, 6, 0, 0, time.UTC),
|
||||
Photo: PhotoFixtures.Pointer("Photo03"),
|
||||
Album: AlbumFixtures.Pointer("light&"),
|
||||
},
|
||||
"10": {
|
||||
PhotoUID: "pt9jtdre2lvl0yh0",
|
||||
AlbumUID: "at1lxuqipotaab23",
|
||||
Hidden: false,
|
||||
Missing: false,
|
||||
Order: 0,
|
||||
CreatedAt: time.Date(2020, 2, 6, 2, 6, 51, 0, time.UTC),
|
||||
UpdatedAt: time.Date(2020, 4, 28, 14, 6, 0, 0, time.UTC),
|
||||
Photo: PhotoFixtures.Pointer("Photo03"),
|
||||
Album: AlbumFixtures.Pointer("pets&dogs"),
|
||||
},
|
||||
"11": {
|
||||
PhotoUID: "pt9jtdre2lvl0yh0",
|
||||
AlbumUID: "at1lxuqipotaab19",
|
||||
Hidden: false,
|
||||
Missing: false,
|
||||
Order: 0,
|
||||
CreatedAt: time.Date(2020, 2, 6, 2, 6, 51, 0, time.UTC),
|
||||
UpdatedAt: time.Date(2020, 4, 28, 14, 6, 0, 0, time.UTC),
|
||||
Photo: PhotoFixtures.Pointer("Photo03"),
|
||||
Album: AlbumFixtures.Pointer("&ilikefood"),
|
||||
},
|
||||
"12": {
|
||||
PhotoUID: "pt9jtdre2lvl0yh0",
|
||||
AlbumUID: "at1lxuqipotaab22",
|
||||
Hidden: false,
|
||||
Missing: false,
|
||||
Order: 0,
|
||||
CreatedAt: time.Date(2020, 2, 6, 2, 6, 51, 0, time.UTC),
|
||||
UpdatedAt: time.Date(2020, 4, 28, 14, 6, 0, 0, time.UTC),
|
||||
Photo: PhotoFixtures.Pointer("Photo03"),
|
||||
Album: AlbumFixtures.Pointer("sale%"),
|
||||
},
|
||||
"13": {
|
||||
PhotoUID: "pt9jtdre2lvl0yh0",
|
||||
AlbumUID: "at1lxuqipotaab21",
|
||||
Hidden: false,
|
||||
Missing: false,
|
||||
Order: 0,
|
||||
CreatedAt: time.Date(2020, 2, 6, 2, 6, 51, 0, time.UTC),
|
||||
UpdatedAt: time.Date(2020, 4, 28, 14, 6, 0, 0, time.UTC),
|
||||
Photo: PhotoFixtures.Pointer("Photo03"),
|
||||
Album: AlbumFixtures.Pointer("%gold"),
|
||||
},
|
||||
"14": {
|
||||
PhotoUID: "pt9jtdre2lvl0yh0",
|
||||
AlbumUID: "at1lxuqipotaab20",
|
||||
Hidden: false,
|
||||
Missing: false,
|
||||
Order: 0,
|
||||
CreatedAt: time.Date(2020, 2, 6, 2, 6, 51, 0, time.UTC),
|
||||
UpdatedAt: time.Date(2020, 4, 28, 14, 6, 0, 0, time.UTC),
|
||||
Photo: PhotoFixtures.Pointer("Photo03"),
|
||||
Album: AlbumFixtures.Pointer("i-love-%-dog"),
|
||||
},
|
||||
}
|
||||
|
||||
// CreatePhotoAlbumFixtures inserts known entities into the database for testing.
|
||||
|
|
Loading…
Reference in a new issue