test: fix tests again

isekai-main
Barış Soner Uşaklı 2 years ago
parent c833d3cdc4
commit 06d1539137

@ -15,7 +15,6 @@ const search = module.exports;
search.search = async function (data) { search.search = async function (data) {
const start = process.hrtime(); const start = process.hrtime();
data.searchIn = data.searchIn || 'titlesposts';
data.sortBy = data.sortBy || 'relevance'; data.sortBy = data.sortBy || 'relevance';
let result; let result;

@ -216,6 +216,7 @@ describe('Search', () => {
it('should not find anything', (done) => { it('should not find anything', (done) => {
search.search({ search.search({
query: 'xxxxxxxxxxxxxx', query: 'xxxxxxxxxxxxxx',
searchIn: 'titles',
}, (err, data) => { }, (err, data) => {
assert.ifError(err); assert.ifError(err);
assert(Array.isArray(data.posts)); assert(Array.isArray(data.posts));

Loading…
Cancel
Save