Move Video class to a separate library
+ improve error handling + youtube-dl update
This commit is contained in:
parent
7d94271a49
commit
5c2823e3f1
30 changed files with 649 additions and 1152 deletions
|
@ -6,9 +6,9 @@
|
|||
|
||||
namespace Alltube\Test;
|
||||
|
||||
use Alltube\Config;
|
||||
use Alltube\Exception\ConfigException;
|
||||
use Alltube\Stream\ConvertedPlaylistArchiveStream;
|
||||
use Alltube\Video;
|
||||
use Exception;
|
||||
|
||||
/**
|
||||
* Unit tests for the ConvertedPlaylistArchiveStream class.
|
||||
|
@ -18,14 +18,16 @@ class ConvertedPlaylistArchiveStreamTest extends StreamTest
|
|||
{
|
||||
/**
|
||||
* Prepare tests.
|
||||
* @throws Exception
|
||||
* @throws ConfigException
|
||||
*/
|
||||
protected function setUp(): void
|
||||
{
|
||||
parent::setUp();
|
||||
|
||||
$video = new Video('https://www.youtube.com/playlist?list=PL1j4Ff8cAqPu5iowaeUAY8lRgkfT4RybJ');
|
||||
$config = Config::getInstance();
|
||||
$downloader = $config->getDownloader();
|
||||
$video = $downloader->getVideo('https://www.youtube.com/playlist?list=PL1j4Ff8cAqPu5iowaeUAY8lRgkfT4RybJ');
|
||||
|
||||
$this->stream = new ConvertedPlaylistArchiveStream($video);
|
||||
$this->stream = new ConvertedPlaylistArchiveStream($downloader, $video);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue