aboutsummaryrefslogtreecommitdiffhomepage
path: root/shared/extra-utils
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2019-07-19 17:30:41 +0200
committerChocobozzz <chocobozzz@cpy.re>2019-07-24 10:58:16 +0200
commit89cd12756035a146bbcc4db78cd3cd64f2f3d88d (patch)
tree896cd9fca1e0baa969b1f7a5b398ec1602761661 /shared/extra-utils
parent09071200c73f5358e1d0bfb61a274e4f2c4ec52b (diff)
downloadPeerTube-89cd12756035a146bbcc4db78cd3cd64f2f3d88d.tar.gz
PeerTube-89cd12756035a146bbcc4db78cd3cd64f2f3d88d.tar.zst
PeerTube-89cd12756035a146bbcc4db78cd3cd64f2f3d88d.zip
Add hook filters tests
Diffstat (limited to 'shared/extra-utils')
-rw-r--r--shared/extra-utils/server/plugins.ts7
-rw-r--r--shared/extra-utils/server/servers.ts3
2 files changed, 8 insertions, 2 deletions
diff --git a/shared/extra-utils/server/plugins.ts b/shared/extra-utils/server/plugins.ts
index 7a5c5344b..2302208a8 100644
--- a/shared/extra-utils/server/plugins.ts
+++ b/shared/extra-utils/server/plugins.ts
@@ -201,6 +201,10 @@ function getPluginPackageJSON (server: ServerInfo, npmName: string) {
201 return readJSON(path) 201 return readJSON(path)
202} 202}
203 203
204function getPluginTestPath (suffix = '') {
205 return join(root(), 'server', 'tests', 'fixtures', 'peertube-plugin-test' + suffix)
206}
207
204export { 208export {
205 listPlugins, 209 listPlugins,
206 listAvailablePlugins, 210 listAvailablePlugins,
@@ -213,5 +217,6 @@ export {
213 getPluginRegisteredSettings, 217 getPluginRegisteredSettings,
214 getPackageJSONPath, 218 getPackageJSONPath,
215 updatePluginPackageJSON, 219 updatePluginPackageJSON,
216 getPluginPackageJSON 220 getPluginPackageJSON,
221 getPluginTestPath
217} 222}
diff --git a/shared/extra-utils/server/servers.ts b/shared/extra-utils/server/servers.ts
index 9167ebe5b..40cf7f0f3 100644
--- a/shared/extra-utils/server/servers.ts
+++ b/shared/extra-utils/server/servers.ts
@@ -171,7 +171,8 @@ async function runServer (server: ServerInfo, configOverrideArg?: any, args = []
171 thumbnails: `test${server.internalServerNumber}/thumbnails/`, 171 thumbnails: `test${server.internalServerNumber}/thumbnails/`,
172 torrents: `test${server.internalServerNumber}/torrents/`, 172 torrents: `test${server.internalServerNumber}/torrents/`,
173 captions: `test${server.internalServerNumber}/captions/`, 173 captions: `test${server.internalServerNumber}/captions/`,
174 cache: `test${server.internalServerNumber}/cache/` 174 cache: `test${server.internalServerNumber}/cache/`,
175 plugins: `test${server.internalServerNumber}/plugins/`
175 }, 176 },
176 admin: { 177 admin: {
177 email: `admin${server.internalServerNumber}@example.com` 178 email: `admin${server.internalServerNumber}@example.com`