diff options
author | Florent <florent.git@zeteo.me> | 2022-11-23 15:50:34 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-11-23 15:50:34 +0100 |
commit | fbad149ff2da2bb0b2fd33b2c8bc7e398f5a12b5 (patch) | |
tree | d445bf4b0bdc6033c5c17c518910010f737ad79c /server/tests/api/search/search-index.ts | |
parent | 77239b425a8e00822a53c9907415832a473c3eb6 (diff) | |
download | PeerTube-fbad149ff2da2bb0b2fd33b2c8bc7e398f5a12b5.tar.gz PeerTube-fbad149ff2da2bb0b2fd33b2c8bc7e398f5a12b5.tar.zst PeerTube-fbad149ff2da2bb0b2fd33b2c8bc7e398f5a12b5.zip |
Fix DISABLE_LOCAL_SEARCH blocking request to local search API (#5411)
Diffstat (limited to 'server/tests/api/search/search-index.ts')
-rw-r--r-- | server/tests/api/search/search-index.ts | 22 |
1 files changed, 0 insertions, 22 deletions
diff --git a/server/tests/api/search/search-index.ts b/server/tests/api/search/search-index.ts index c61ac441d..eae4391ec 100644 --- a/server/tests/api/search/search-index.ts +++ b/server/tests/api/search/search-index.ts | |||
@@ -81,28 +81,6 @@ describe('Test index search', function () { | |||
81 | const body = await command.searchChannels({ search: 'root' }) | 81 | const body = await command.searchChannels({ search: 'root' }) |
82 | expect(body.total).to.be.greaterThan(2) | 82 | expect(body.total).to.be.greaterThan(2) |
83 | }) | 83 | }) |
84 | |||
85 | it('Should make an index videos search if local search is disabled', async function () { | ||
86 | await server.config.updateCustomSubConfig({ | ||
87 | newConfig: { | ||
88 | search: { | ||
89 | searchIndex: { | ||
90 | enabled: true, | ||
91 | isDefaultSearch: false, | ||
92 | disableLocalSearch: true | ||
93 | } | ||
94 | } | ||
95 | } | ||
96 | }) | ||
97 | |||
98 | const body = await command.searchVideos({ search: 'local video' }) | ||
99 | expect(body.total).to.be.greaterThan(2) | ||
100 | }) | ||
101 | |||
102 | it('Should make an index channels search if local search is disabled', async function () { | ||
103 | const body = await command.searchChannels({ search: 'root' }) | ||
104 | expect(body.total).to.be.greaterThan(2) | ||
105 | }) | ||
106 | }) | 84 | }) |
107 | 85 | ||
108 | describe('Videos search', async function () { | 86 | describe('Videos search', async function () { |