summaryrefslogtreecommitdiff
path: root/internal/processing/processor_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'internal/processing/processor_test.go')
-rw-r--r--internal/processing/processor_test.go13
1 files changed, 9 insertions, 4 deletions
diff --git a/internal/processing/processor_test.go b/internal/processing/processor_test.go
index 40a4ecba6..7e1972366 100644
--- a/internal/processing/processor_test.go
+++ b/internal/processing/processor_test.go
@@ -34,11 +34,13 @@ import (
"github.com/superseriousbusiness/gotosocial/internal/federation"
"github.com/superseriousbusiness/gotosocial/internal/gtsmodel"
"github.com/superseriousbusiness/gotosocial/internal/media"
+ "github.com/superseriousbusiness/gotosocial/internal/messages"
"github.com/superseriousbusiness/gotosocial/internal/oauth"
"github.com/superseriousbusiness/gotosocial/internal/processing"
"github.com/superseriousbusiness/gotosocial/internal/timeline"
"github.com/superseriousbusiness/gotosocial/internal/transport"
"github.com/superseriousbusiness/gotosocial/internal/typeutils"
+ "github.com/superseriousbusiness/gotosocial/internal/worker"
"github.com/superseriousbusiness/gotosocial/testrig"
)
@@ -215,17 +217,20 @@ func (suite *ProcessingStandardTestSuite) SetupTest() {
}, nil
})
- suite.transportController = testrig.NewTestTransportController(httpClient, suite.db)
+ clientWorker := worker.New[messages.FromClientAPI](-1, -1)
+ fedWorker := worker.New[messages.FromFederator](-1, -1)
+
+ suite.transportController = testrig.NewTestTransportController(httpClient, suite.db, fedWorker)
suite.mediaManager = testrig.NewTestMediaManager(suite.db, suite.storage)
- suite.federator = testrig.NewTestFederator(suite.db, suite.transportController, suite.storage, suite.mediaManager)
+ suite.federator = testrig.NewTestFederator(suite.db, suite.transportController, suite.storage, suite.mediaManager, fedWorker)
suite.oauthServer = testrig.NewTestOauthServer(suite.db)
suite.emailSender = testrig.NewEmailSender("../../web/template/", nil)
- suite.processor = processing.NewProcessor(suite.typeconverter, suite.federator, suite.oauthServer, suite.mediaManager, suite.storage, suite.db, suite.emailSender)
+ suite.processor = processing.NewProcessor(suite.typeconverter, suite.federator, suite.oauthServer, suite.mediaManager, suite.storage, suite.db, suite.emailSender, clientWorker, fedWorker)
testrig.StandardDBSetup(suite.db, suite.testAccounts)
testrig.StandardStorageSetup(suite.storage, "../../testrig/media")
- if err := suite.processor.Start(context.Background()); err != nil {
+ if err := suite.processor.Start(); err != nil {
panic(err)
}
}