fix: use InDelta for float comparison in tests

This commit is contained in:
kolaente 2026-04-02 19:05:11 +02:00 committed by kolaente
parent 0c3d01099f
commit 104c8eadae
1 changed files with 2 additions and 2 deletions

View File

@ -486,8 +486,8 @@ func TestCreateTaskPositionConflictResolution(t *testing.T) {
_, err = s.Where("task_id = ? AND project_view_id = ?", 701, 1).Get(&updated2)
require.NoError(t, err)
assert.Equal(t, 11111.0, updated1.Position)
assert.Equal(t, 22222.0, updated2.Position)
assert.InDelta(t, 11111.0, updated1.Position, 0)
assert.InDelta(t, 22222.0, updated2.Position, 0)
})
}