diff --git a/internal/store/postgres/grant_repository_test.go b/internal/store/postgres/grant_repository_test.go index b0709374a..6fb5a1c7e 100644 --- a/internal/store/postgres/grant_repository_test.go +++ b/internal/store/postgres/grant_repository_test.go @@ -103,6 +103,17 @@ func (s *GrantRepositoryTestSuite) SetupSuite() { s.Require().NoError(err) } +func (s *GrantRepositoryTestSuite) AfterTest(suiteName, testName string) { + // clean grants table + db, err := s.store.DB().DB() + if err != nil { + s.T().Fatal(err) + } + if _, err := db.Exec("DELETE FROM grants"); err != nil { + s.T().Fatal(err) + } +} + func (s *GrantRepositoryTestSuite) TearDownSuite() { // Clean tests db, err := s.store.DB().DB()