add test and openapi for hot sort parameter

This commit is contained in:
Rigel Kent
2021-01-28 14:43:02 +01:00
committed by Chocobozzz
parent ba5d4a849c
commit 923d3d5ad5
3 changed files with 12 additions and 1 deletions

View File

@@ -355,6 +355,14 @@ describe('Test a single server', function () {
expect(videos.length).to.equal(2)
})
it('Should list and sort by hotness in descending order', async function () {
const res = await getVideosListPagination(server.url, 0, 2, '-hot')
const videos = res.body.data
expect(res.body.total).to.equal(6)
expect(videos.length).to.equal(2)
})
it('Should update a video', async function () {
const attributes = {
name: 'my super video updated',