Tests: Add to dos to run tests on mariadb
This commit is contained in:
parent
a62f49e824
commit
d27e1fa52f
|
@ -229,6 +229,7 @@ func TestAccount_Update(t *testing.T) {
|
|||
})
|
||||
}
|
||||
|
||||
//TODO fails on mariadb
|
||||
func TestAccount_Save(t *testing.T) {
|
||||
t.Run("success", func(t *testing.T) {
|
||||
account := Account{AccName: "DeleteAccount", AccOwner: "Delete", AccURL: "test.com", AccType: "test", AccKey: "123", AccUser: "testuser", AccPass: "testpass",
|
||||
|
|
|
@ -1,10 +1,9 @@
|
|||
package entity
|
||||
|
||||
import (
|
||||
"github.com/stretchr/testify/assert"
|
||||
"testing"
|
||||
"time"
|
||||
|
||||
"github.com/stretchr/testify/assert"
|
||||
)
|
||||
|
||||
func TestFirstOrCreateDetails(t *testing.T) {
|
||||
|
@ -143,6 +142,7 @@ func TestNewDetails(t *testing.T) {
|
|||
})
|
||||
}
|
||||
|
||||
//TODO fails on mariadb
|
||||
func TestDetails_Create(t *testing.T) {
|
||||
t.Run("error", func(t *testing.T) {
|
||||
details := Details{PhotoID: 0}
|
||||
|
@ -160,6 +160,7 @@ func TestDetails_Create(t *testing.T) {
|
|||
})
|
||||
}
|
||||
|
||||
//TODO fails on mariadb
|
||||
func TestDetails_Save(t *testing.T) {
|
||||
t.Run("success", func(t *testing.T) {
|
||||
details := Details{PhotoID: 123678955432, UpdatedAt: time.Date(2020, 2, 1, 0, 0, 0, 0, time.UTC)}
|
||||
|
|
|
@ -245,6 +245,7 @@ func TestMarker_InvalidArea(t *testing.T) {
|
|||
})
|
||||
}
|
||||
|
||||
//TODO fails on mariadb
|
||||
func TestMarker_Save(t *testing.T) {
|
||||
t.Run("success", func(t *testing.T) {
|
||||
m := NewMarker(FileFixtures.Get("exampleFileName.jpg"), testArea, "lt9k3pw1wowuy3c4", SrcImage, MarkerLabel, 100, 65)
|
||||
|
|
|
@ -43,6 +43,7 @@ func TestPassword_InvalidPasswordPassword(t *testing.T) {
|
|||
})
|
||||
}
|
||||
|
||||
//TODO fails on mariadb
|
||||
func TestPassword_Create(t *testing.T) {
|
||||
t.Run("success", func(t *testing.T) {
|
||||
p := Password{}
|
||||
|
|
|
@ -38,6 +38,7 @@ func TestFirstOrCreatePhotoAlbum(t *testing.T) {
|
|||
t.Errorf("PhotoUID should be the same: %s %s", result.PhotoUID, model.PhotoUID)
|
||||
}
|
||||
})
|
||||
//TODO fails on mariadb
|
||||
t.Run("not yet existing album", func(t *testing.T) {
|
||||
model := &PhotoAlbum{}
|
||||
result := FirstOrCreatePhotoAlbum(model)
|
||||
|
@ -56,6 +57,7 @@ func TestFirstOrCreatePhotoAlbum(t *testing.T) {
|
|||
})
|
||||
}
|
||||
|
||||
//TODO fails on mariadb
|
||||
func TestPhotoAlbum_Save(t *testing.T) {
|
||||
t.Run("success", func(t *testing.T) {
|
||||
p := PhotoAlbum{}
|
||||
|
|
|
@ -64,6 +64,7 @@ func TestPhotoLabel_Save(t *testing.T) {
|
|||
t.Fatal(err)
|
||||
}
|
||||
})
|
||||
//TODO fails on mariadb
|
||||
t.Run("photo not nil and label not nil", func(t *testing.T) {
|
||||
label := &Label{LabelName: "LabelSaveUnique", LabelSlug: "unique-slug"}
|
||||
photo := &Photo{}
|
||||
|
|
|
@ -213,6 +213,8 @@ func TestSubject_Update(t *testing.T) {
|
|||
})
|
||||
|
||||
}
|
||||
|
||||
//TODO fails on mariadb
|
||||
func TestSubject_Updates(t *testing.T) {
|
||||
t.Run("success", func(t *testing.T) {
|
||||
m := NewSubject("Update Me", SubjPerson, SrcAuto)
|
||||
|
|
|
@ -85,6 +85,7 @@ func TestFilesByUID(t *testing.T) {
|
|||
}
|
||||
assert.Equal(t, 0, len(files))
|
||||
})
|
||||
//TODO fails on mariadb
|
||||
t.Run("error", func(t *testing.T) {
|
||||
files, err := FilesByUID([]string{"ft8es39w45bnlxxx"}, -100, 0)
|
||||
|
||||
|
|
Loading…
Reference in a new issue