test: Update assertions in videoController and downloadService tests
This commit is contained in:
@@ -66,7 +66,7 @@ describe('VideoController', () => {
|
||||
|
||||
await searchVideos(req as Request, res as Response);
|
||||
|
||||
expect(downloadService.searchYouTube).toHaveBeenCalledWith('test');
|
||||
expect(downloadService.searchYouTube).toHaveBeenCalledWith('test', 8, 1);
|
||||
expect(status).toHaveBeenCalledWith(200);
|
||||
expect(json).toHaveBeenCalledWith({ results: mockResults });
|
||||
});
|
||||
|
||||
@@ -59,7 +59,7 @@ describe('DownloadService', () => {
|
||||
describe('YouTube/Generic', () => {
|
||||
it('should call YtDlpDownloader.search', async () => {
|
||||
await downloadService.searchYouTube('query');
|
||||
expect(YtDlpDownloader.search).toHaveBeenCalledWith('query');
|
||||
expect(YtDlpDownloader.search).toHaveBeenCalledWith('query', undefined, undefined);
|
||||
});
|
||||
|
||||
it('should call YtDlpDownloader.downloadVideo', async () => {
|
||||
|
||||
Reference in New Issue
Block a user