Skip to content

Commit dc99357

Browse files
committed
Ignore corrupted data for action table when getting feed, users should fix the database themselves
1 parent a397796 commit dc99357

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

models/activities/action_test.go

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -228,6 +228,8 @@ func TestNotifyWatchers(t *testing.T) {
228228
}
229229

230230
func TestGetFeedsCorrupted(t *testing.T) {
231+
// Now we will not check for corrupted data in the feeds
232+
// users should run doctor to fix their data
231233
assert.NoError(t, unittest.PrepareTestDatabase())
232234
user := unittest.AssertExistsAndLoadBean(t, &user_model.User{ID: 1})
233235
unittest.AssertExistsAndLoadBean(t, &activities_model.Action{
@@ -241,8 +243,8 @@ func TestGetFeedsCorrupted(t *testing.T) {
241243
IncludePrivate: true,
242244
})
243245
assert.NoError(t, err)
244-
assert.Len(t, actions, 0)
245-
assert.Equal(t, int64(0), count)
246+
assert.Len(t, actions, 1)
247+
assert.Equal(t, int64(1), count)
246248
}
247249

248250
func TestConsistencyUpdateAction(t *testing.T) {

0 commit comments

Comments
 (0)