Fix tests
authorChocobozzz <me@florianbigard.com>
Wed, 4 Sep 2019 13:50:40 +0000 (15:50 +0200)
committerChocobozzz <chocobozzz@cpy.re>
Wed, 4 Sep 2019 14:24:58 +0000 (16:24 +0200)
server/lib/activitypub/follow.ts
server/tests/api/server/auto-follows.ts

index c57e43c9107c73ee91a5e02d3de633e431d2ae53..1abf43cd40020138a6e014fd68aa3d7cc8805d50 100644 (file)
@@ -4,7 +4,7 @@ import { SERVER_ACTOR_NAME } from '../../initializers/constants'
 import { JobQueue } from '../job-queue'
 import { logger } from '../../helpers/logger'
 import { getServerActor } from '../../helpers/utils'
-import { ServerModel } from '@server/models/server/server'
+import { ServerModel } from '../../models/server/server'
 
 async function autoFollowBackIfNeeded (actorFollow: MActorFollowActors) {
   if (!CONFIG.FOLLOWINGS.INSTANCE.AUTO_FOLLOW_BACK.ENABLED) return
index dea9191f27b970aac4f189a7c1823324d076dcf4..df468034cf6e4dd3e64bbe7234bb5f81c81c7537 100644 (file)
@@ -143,6 +143,10 @@ describe('Test auto follows', function () {
       await checkFollow(servers[1], servers[0], true)
 
       await resetFollows(servers)
+
+      config.followings.instance.autoFollowBack.enabled = false
+      config.followers.instance.manualApproval = false
+      await updateCustomSubConfig(servers[1].url, servers[1].accessToken, config)
     })
   })