summaryrefslogtreecommitdiff
path: root/cmd
diff options
context:
space:
mode:
authorLibravatar tobi <31960611+tsmethurst@users.noreply.github.com>2024-07-17 16:46:52 +0200
committerLibravatar GitHub <noreply@github.com>2024-07-17 16:46:52 +0200
commit0aadc2db2a42fc99538fbbb096b84b209b9ccd68 (patch)
tree38c58d163004d43da80d33477a6e9f22547bdb15 /cmd
parentgive read-only access to /dev for ffmpeg to access /dev/urandom (#3109) (diff)
downloadgotosocial-0aadc2db2a42fc99538fbbb096b84b209b9ccd68.tar.xz
[feature] Allow users to set default interaction policies per status visibility (#3108)
* [feature] Allow users to set default interaction policies * use vars for default policies * avoid some code repetition * unfuck form binding * avoid bonkers loop * beep boop * put policyValsToAPIPolicyVals in separate function * don't bother with slices.Grow * oops
Diffstat (limited to 'cmd')
-rw-r--r--cmd/gotosocial/action/testrig/testrig.go8
1 files changed, 4 insertions, 4 deletions
diff --git a/cmd/gotosocial/action/testrig/testrig.go b/cmd/gotosocial/action/testrig/testrig.go
index 7b99a2a13..99f366fbe 100644
--- a/cmd/gotosocial/action/testrig/testrig.go
+++ b/cmd/gotosocial/action/testrig/testrig.go
@@ -155,10 +155,6 @@ var Start action.GTSAction = func(ctx context.Context) error {
}
testrig.StandardStorageSetup(state.Storage, "./testrig/media")
- // Initialize workers.
- testrig.StartNoopWorkers(state)
- defer testrig.StopWorkers(state)
-
// build backend handlers
transportController := testrig.NewTestTransportController(state, testrig.NewMockHTTPClient(func(req *http.Request) (*http.Response, error) {
r := io.NopCloser(bytes.NewReader([]byte{}))
@@ -199,6 +195,10 @@ var Start action.GTSAction = func(ctx context.Context) error {
processor := testrig.NewTestProcessor(state, federator, emailSender, mediaManager)
+ // Initialize workers.
+ testrig.StartWorkers(state, processor.Workers())
+ defer testrig.StopWorkers(state)
+
// Initialize metrics.
if err := metrics.Initialize(state.DB); err != nil {
return fmt.Errorf("error initializing metrics: %w", err)