Add test for removing bug from cache

This commit is contained in:
vince 2020-07-20 18:08:37 +08:00 committed by Michael Muré
parent 4e4ca106ae
commit 7dbcca84c7
No known key found for this signature in database
GPG Key ID: A4457C029293126F

View File

@ -101,6 +101,11 @@ func TestCache(t *testing.T) {
require.NoError(t, err)
_, err = cache.ResolveBugPrefix(bug1.Id().String()[:10])
require.NoError(t, err)
// Possible to delete a bug
err = cache.RemoveBug([]string{bug1.Id().Human()})
require.NoError(t, err)
require.Equal(t, len(cache.AllBugsIds()), 1)
}
func TestPushPull(t *testing.T) {