diff options
Diffstat (limited to 'internal/db/users_test.go')
-rw-r--r-- | internal/db/users_test.go | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/internal/db/users_test.go b/internal/db/users_test.go index edb9c1dd..d83ffe50 100644 --- a/internal/db/users_test.go +++ b/internal/db/users_test.go @@ -68,10 +68,12 @@ func TestUser_AfterFind(t *testing.T) { } user := &User{ + FullName: "user1<script src=http://localhost:8181/xss.js>", CreatedUnix: now.Unix(), UpdatedUnix: now.Unix(), } _ = user.AfterFind(db) + assert.Equal(t, "user1", user.FullName) assert.Equal(t, user.CreatedUnix, user.Created.Unix()) assert.Equal(t, user.UpdatedUnix, user.Updated.Unix()) } |