diff options
Diffstat (limited to 'model/oauth_test.go')
-rw-r--r-- | model/oauth_test.go | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/model/oauth_test.go b/model/oauth_test.go index 2ba36666c..e1f88a993 100644 --- a/model/oauth_test.go +++ b/model/oauth_test.go @@ -14,6 +14,7 @@ func TestOAuthAppJson(t *testing.T) { a1.Name = "TestOAuthApp" + NewId() a1.CallbackUrls = []string{"https://nowhere.com"} a1.Homepage = "https://nowhere.com" + a1.IconURL = "https://nowhere.com/icon_image.png" a1.ClientSecret = NewId() json := a1.ToJson() @@ -30,6 +31,7 @@ func TestOAuthAppPreSave(t *testing.T) { a1.Name = "TestOAuthApp" + NewId() a1.CallbackUrls = []string{"https://nowhere.com"} a1.Homepage = "https://nowhere.com" + a1.IconURL = "https://nowhere.com/icon_image.png" a1.ClientSecret = NewId() a1.PreSave() a1.Etag() @@ -42,6 +44,7 @@ func TestOAuthAppPreUpdate(t *testing.T) { a1.Name = "TestOAuthApp" + NewId() a1.CallbackUrls = []string{"https://nowhere.com"} a1.Homepage = "https://nowhere.com" + a1.IconURL = "https://nowhere.com/icon_image.png" a1.ClientSecret = NewId() a1.PreUpdate() } @@ -92,4 +95,9 @@ func TestOAuthAppIsValid(t *testing.T) { if err := app.IsValid(); err != nil { t.Fatal() } + + app.IconURL = "https://nowhere.com/icon_image.png" + if err := app.IsValid(); err != nil { + t.Fatal() + } } |