mirror of
https://github.com/crazywhalecc/static-php-cli.git
synced 2026-07-07 08:45:40 +08:00
Add new tests, remove redundant code
This commit is contained in:
46
tests/SPC/store/DownloaderTest.php
Normal file
46
tests/SPC/store/DownloaderTest.php
Normal file
@@ -0,0 +1,46 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace SPC\Tests\store;
|
||||
|
||||
use PHPUnit\Framework\TestCase;
|
||||
use SPC\store\Downloader;
|
||||
|
||||
/**
|
||||
* @internal
|
||||
* TODO: Test all methods
|
||||
*/
|
||||
class DownloaderTest extends TestCase
|
||||
{
|
||||
public function testGetLatestGithubTarball()
|
||||
{
|
||||
$this->assertEquals(
|
||||
'https://api.github.com/repos/AOMediaCodec/libavif/tarball/v1.1.1',
|
||||
Downloader::getLatestGithubTarball('libavif', [
|
||||
'type' => 'ghtar',
|
||||
'repo' => 'AOMediaCodec/libavif',
|
||||
])[0]
|
||||
);
|
||||
}
|
||||
|
||||
public function testDownloadGit() {}
|
||||
|
||||
public function testDownloadFile() {}
|
||||
|
||||
public function testLockSource() {}
|
||||
|
||||
public function testGetLatestBitbucketTag() {}
|
||||
|
||||
public function testGetLatestGithubRelease() {}
|
||||
|
||||
public function testCurlExec() {}
|
||||
|
||||
public function testCurlDown() {}
|
||||
|
||||
public function testDownloadSource() {}
|
||||
|
||||
public function testGetFromFileList() {}
|
||||
|
||||
public function testDownloadPackage() {}
|
||||
}
|
||||
Reference in New Issue
Block a user