From b315eee43b1e40a10ddf95786e516a4ac459510c Mon Sep 17 00:00:00 2001 From: tobi <31960611+tsmethurst@users.noreply.github.com> Date: Mon, 20 Sep 2021 16:46:45 +0200 Subject: Update webfingering a little, add tests (#236) * Update webfingering a little, add tests * fix broken tests oops --- internal/api/s2s/user/repliesget_test.go | 30 ------------------------------ 1 file changed, 30 deletions(-) (limited to 'internal/api/s2s/user/repliesget_test.go') diff --git a/internal/api/s2s/user/repliesget_test.go b/internal/api/s2s/user/repliesget_test.go index a785b2cff..ccd2eb4f6 100644 --- a/internal/api/s2s/user/repliesget_test.go +++ b/internal/api/s2s/user/repliesget_test.go @@ -15,7 +15,6 @@ import ( "github.com/stretchr/testify/assert" "github.com/stretchr/testify/suite" "github.com/superseriousbusiness/gotosocial/internal/api/s2s/user" - "github.com/superseriousbusiness/gotosocial/internal/api/security" "github.com/superseriousbusiness/gotosocial/testrig" ) @@ -23,35 +22,6 @@ type RepliesGetTestSuite struct { UserStandardTestSuite } -func (suite *RepliesGetTestSuite) SetupSuite() { - suite.testTokens = testrig.NewTestTokens() - suite.testClients = testrig.NewTestClients() - suite.testApplications = testrig.NewTestApplications() - suite.testUsers = testrig.NewTestUsers() - suite.testAccounts = testrig.NewTestAccounts() - suite.testAttachments = testrig.NewTestAttachments() - suite.testStatuses = testrig.NewTestStatuses() -} - -func (suite *RepliesGetTestSuite) SetupTest() { - suite.config = testrig.NewTestConfig() - suite.db = testrig.NewTestDB() - suite.tc = testrig.NewTestTypeConverter(suite.db) - suite.storage = testrig.NewTestStorage() - suite.log = testrig.NewTestLog() - suite.federator = testrig.NewTestFederator(suite.db, testrig.NewTestTransportController(testrig.NewMockHTTPClient(nil), suite.db), suite.storage) - suite.processor = testrig.NewTestProcessor(suite.db, suite.storage, suite.federator) - suite.userModule = user.New(suite.config, suite.processor, suite.log).(*user.Module) - suite.securityModule = security.New(suite.config, suite.db, suite.log).(*security.Module) - testrig.StandardDBSetup(suite.db, suite.testAccounts) - testrig.StandardStorageSetup(suite.storage, "../../../../testrig/media") -} - -func (suite *RepliesGetTestSuite) TearDownTest() { - testrig.StandardDBTeardown(suite.db) - testrig.StandardStorageTeardown(suite.storage) -} - func (suite *RepliesGetTestSuite) TestGetReplies() { // the dereference we're gonna use derefRequests := testrig.NewTestDereferenceRequests(suite.testAccounts) -- cgit v1.2.3