From 70dadb1916bfef8ba8cbc4e9b042cc8740f45e28 Mon Sep 17 00:00:00 2001 From: Gusted Date: Fri, 21 Jul 2023 04:54:06 +0200 Subject: [PATCH] [MODERATION] Add test case (squash) - Add an test case, to test an property of the function. --- models/user/block_test.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/models/user/block_test.go b/models/user/block_test.go index a368bb35d7..629c0c975a 100644 --- a/models/user/block_test.go +++ b/models/user/block_test.go @@ -49,6 +49,8 @@ func TestListBlockedUsers(t *testing.T) { assert.NoError(t, err) if assert.Len(t, blockedUsers, 1) { assert.EqualValues(t, 1, blockedUsers[0].ID) + // The function returns the created Unix of the block, not that of the user. + assert.EqualValues(t, 1671607299, blockedUsers[0].CreatedUnix) } }