This commit is contained in:
kolaente 2018-07-27 16:28:28 +02:00
parent 51064f3d8f
commit d556162591
No known key found for this signature in database
GPG Key ID: F40E70337AB24C9B
1 changed files with 4 additions and 4 deletions

View File

@ -1,16 +1,16 @@
package models package models
import ( import (
"testing"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
"reflect" "reflect"
"testing"
) )
func TestTeam_Create(t *testing.T) { func TestTeam_Create(t *testing.T) {
//Dummyteam //Dummyteam
dummyteam := Team{ dummyteam := Team{
Name:"Testteam293", Name: "Testteam293",
Description:"Lorem Ispum", Description: "Lorem Ispum",
} }
// Doer // Doer
@ -23,7 +23,7 @@ func TestTeam_Create(t *testing.T) {
assert.NoError(t, err) assert.NoError(t, err)
// Check if it was inserted and we're admin // Check if it was inserted and we're admin
tm := Team{ID:dummyteam.ID} tm := Team{ID: dummyteam.ID}
err = tm.ReadOne() err = tm.ReadOne()
assert.NoError(t, err) assert.NoError(t, err)
assert.Equal(t, 1, len(tm.Members)) assert.Equal(t, 1, len(tm.Members))