aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--server/lib/activitypub/process/process-create.ts2
-rw-r--r--server/lib/activitypub/process/process-like.ts2
-rw-r--r--server/tests/api/activitypub/client.ts2
-rw-r--r--server/tests/api/activitypub/fetch.ts4
-rw-r--r--server/tests/api/activitypub/helpers.ts2
-rw-r--r--server/tests/api/activitypub/security.ts11
-rw-r--r--server/tests/api/server/no-client.ts4
-rw-r--r--shared/utils/index.ts2
8 files changed, 18 insertions, 11 deletions
diff --git a/server/lib/activitypub/process/process-create.ts b/server/lib/activitypub/process/process-create.ts
index 214e14546..9a72cb899 100644
--- a/server/lib/activitypub/process/process-create.ts
+++ b/server/lib/activitypub/process/process-create.ts
@@ -12,7 +12,7 @@ import { getOrCreateVideoAndAccountAndChannel } from '../videos'
12import { forwardVideoRelatedActivity } from '../send/utils' 12import { forwardVideoRelatedActivity } from '../send/utils'
13import { Redis } from '../../redis' 13import { Redis } from '../../redis'
14import { createOrUpdateCacheFile } from '../cache-file' 14import { createOrUpdateCacheFile } from '../cache-file'
15import { immutableAssign } from '../../../tests/utils' 15import { immutableAssign } from '../../../../shared/utils'
16import { getVideoDislikeActivityPubUrl } from '../url' 16import { getVideoDislikeActivityPubUrl } from '../url'
17import { VideoModel } from '../../../models/video/video' 17import { VideoModel } from '../../../models/video/video'
18 18
diff --git a/server/lib/activitypub/process/process-like.ts b/server/lib/activitypub/process/process-like.ts
index 0dca17551..be86665e9 100644
--- a/server/lib/activitypub/process/process-like.ts
+++ b/server/lib/activitypub/process/process-like.ts
@@ -5,7 +5,7 @@ import { AccountVideoRateModel } from '../../../models/account/account-video-rat
5import { ActorModel } from '../../../models/activitypub/actor' 5import { ActorModel } from '../../../models/activitypub/actor'
6import { forwardVideoRelatedActivity } from '../send/utils' 6import { forwardVideoRelatedActivity } from '../send/utils'
7import { getOrCreateVideoAndAccountAndChannel } from '../videos' 7import { getOrCreateVideoAndAccountAndChannel } from '../videos'
8import { immutableAssign } from '../../../tests/utils' 8import { immutableAssign } from '../../../../shared/utils'
9import { getVideoDislikeActivityPubUrl, getVideoLikeActivityPubUrl } from '../url' 9import { getVideoDislikeActivityPubUrl, getVideoLikeActivityPubUrl } from '../url'
10 10
11async function processLikeActivity (activity: ActivityLike, byActor: ActorModel) { 11async function processLikeActivity (activity: ActivityLike, byActor: ActorModel) {
diff --git a/server/tests/api/activitypub/client.ts b/server/tests/api/activitypub/client.ts
index 334cd4e5c..d45232c8d 100644
--- a/server/tests/api/activitypub/client.ts
+++ b/server/tests/api/activitypub/client.ts
@@ -9,7 +9,7 @@ import {
9 runServer, 9 runServer,
10 ServerInfo, 10 ServerInfo,
11 setAccessTokensToServers 11 setAccessTokensToServers
12} from '../../shared/utils' 12} from '../../../../shared/utils'
13 13
14 14
15const expect = chai.expect 15const expect = chai.expect
diff --git a/server/tests/api/activitypub/fetch.ts b/server/tests/api/activitypub/fetch.ts
index a42c606c6..e84eb18bb 100644
--- a/server/tests/api/activitypub/fetch.ts
+++ b/server/tests/api/activitypub/fetch.ts
@@ -13,10 +13,10 @@ import {
13 setAccessTokensToServers, 13 setAccessTokensToServers,
14 uploadVideo, 14 uploadVideo,
15 userLogin 15 userLogin
16} from '../../utils' 16} from '../../../../shared/utils'
17import * as chai from 'chai' 17import * as chai from 'chai'
18import { setActorField, setVideoField } from '../../utils/miscs/sql' 18import { setActorField, setVideoField } from '../../utils/miscs/sql'
19import { waitJobs } from '../../utils/server/jobs' 19import { waitJobs } from '../../../../shared/utils/server/jobs'
20import { Video } from '../../../../shared/models/videos' 20import { Video } from '../../../../shared/models/videos'
21 21
22const expect = chai.expect 22const expect = chai.expect
diff --git a/server/tests/api/activitypub/helpers.ts b/server/tests/api/activitypub/helpers.ts
index 610846247..4c42f3d67 100644
--- a/server/tests/api/activitypub/helpers.ts
+++ b/server/tests/api/activitypub/helpers.ts
@@ -2,7 +2,7 @@
2 2
3import 'mocha' 3import 'mocha'
4import { expect } from 'chai' 4import { expect } from 'chai'
5import { buildRequestStub } from '../../utils' 5import { buildRequestStub } from '../../utils/miscs/stubs'
6import { isHTTPSignatureVerified, isJsonLDSignatureVerified, parseHTTPSignature } from '../../../helpers/peertube-crypto' 6import { isHTTPSignatureVerified, isJsonLDSignatureVerified, parseHTTPSignature } from '../../../helpers/peertube-crypto'
7import { cloneDeep } from 'lodash' 7import { cloneDeep } from 'lodash'
8import { buildSignedActivity } from '../../../helpers/activitypub' 8import { buildSignedActivity } from '../../../helpers/activitypub'
diff --git a/server/tests/api/activitypub/security.ts b/server/tests/api/activitypub/security.ts
index e7899bb14..69b7c0148 100644
--- a/server/tests/api/activitypub/security.ts
+++ b/server/tests/api/activitypub/security.ts
@@ -2,7 +2,16 @@
2 2
3import 'mocha' 3import 'mocha'
4 4
5import { flushAndRunMultipleServers, flushTests, killallServers, makePOSTAPRequest, makeFollowRequest, ServerInfo } from '../../utils' 5import {
6 flushAndRunMultipleServers,
7 flushTests,
8 killallServers,
9 ServerInfo
10} from '../../../../shared/utils'
11import {
12 makePOSTAPRequest,
13 makeFollowRequest,
14} from '../../utils/requests/activitypub'
6import { HTTP_SIGNATURE } from '../../../initializers' 15import { HTTP_SIGNATURE } from '../../../initializers'
7import { buildDigest, buildGlobalHeaders } from '../../../lib/job-queue/handlers/utils/activitypub-http-utils' 16import { buildDigest, buildGlobalHeaders } from '../../../lib/job-queue/handlers/utils/activitypub-http-utils'
8import * as chai from 'chai' 17import * as chai from 'chai'
diff --git a/server/tests/api/server/no-client.ts b/server/tests/api/server/no-client.ts
index 6d6ce8532..3b95ce945 100644
--- a/server/tests/api/server/no-client.ts
+++ b/server/tests/api/server/no-client.ts
@@ -4,8 +4,8 @@ import {
4 flushTests, 4 flushTests,
5 killallServers, 5 killallServers,
6 ServerInfo 6 ServerInfo
7} from '../../utils/index' 7} from '../../../../shared/utils'
8import { runServer } from '../../utils/server/servers' 8import { runServer } from '../../../../shared/utils/server/servers'
9 9
10describe('Start and stop server without web client routes', function () { 10describe('Start and stop server without web client routes', function () {
11 let server: ServerInfo 11 let server: ServerInfo
diff --git a/shared/utils/index.ts b/shared/utils/index.ts
index 905d93823..897389824 100644
--- a/shared/utils/index.ts
+++ b/shared/utils/index.ts
@@ -4,10 +4,8 @@ export * from './server/clients'
4export * from './server/config' 4export * from './server/config'
5export * from './users/login' 5export * from './users/login'
6export * from './miscs/miscs' 6export * from './miscs/miscs'
7export * from './miscs/stubs'
8export * from './server/follows' 7export * from './server/follows'
9export * from './requests/requests' 8export * from './requests/requests'
10export * from './requests/activitypub'
11export * from './server/servers' 9export * from './server/servers'
12export * from './videos/services' 10export * from './videos/services'
13export * from './users/users' 11export * from './users/users'