mirror of
https://codeberg.org/demostf/api.git
synced 2026-06-03 18:04:08 +02:00
fix test
This commit is contained in:
parent
c93a1c20d3
commit
9543b141ab
2 changed files with 7 additions and 3 deletions
|
|
@ -18,6 +18,7 @@ use Demostf\API\Providers\KillProvider;
|
|||
use Demostf\API\Providers\PlayerProvider;
|
||||
use Demostf\API\Providers\UserProvider;
|
||||
use Demostf\API\Test\TestCase;
|
||||
use Doctrine\DBAL\Connection;
|
||||
|
||||
class DemoSaverTest extends TestCase {
|
||||
public function testSave() {
|
||||
|
|
@ -76,7 +77,8 @@ class DemoSaverTest extends TestCase {
|
|||
new PlayerProvider($this->getDatabaseConnection()),
|
||||
$chatProvider,
|
||||
$userProvider,
|
||||
$demoProvider
|
||||
$demoProvider,
|
||||
$this->createMock(Connection::class)
|
||||
);
|
||||
|
||||
$storedDemo = new StoredDemo('http://example.com/foo', 'foo', 'example');
|
||||
|
|
|
|||
|
|
@ -19,6 +19,7 @@ use Demostf\API\Providers\PlayerProvider;
|
|||
use Demostf\API\Providers\UploadProvider;
|
||||
use Demostf\API\Providers\UserProvider;
|
||||
use Demostf\API\Test\TestCase;
|
||||
use Doctrine\DBAL\Connection;
|
||||
|
||||
class UploadProviderTest extends TestCase {
|
||||
/** @var RawParser */
|
||||
|
|
@ -70,7 +71,8 @@ class UploadProviderTest extends TestCase {
|
|||
new PlayerProvider($this->getDatabaseConnection()),
|
||||
new ChatProvider($this->getDatabaseConnection()),
|
||||
$this->userProvider,
|
||||
$this->demoProvider
|
||||
$this->demoProvider,
|
||||
$this->createMock(Connection::class)
|
||||
);
|
||||
|
||||
$this->uploadProvider = new UploadProvider(
|
||||
|
|
@ -128,7 +130,7 @@ class UploadProviderTest extends TestCase {
|
|||
}
|
||||
|
||||
public function testValidateHeaderToBig() {
|
||||
$this->assertEquals('Demos cant be more than 150MB in size', $this->uploadProvider->validateHeader(
|
||||
$this->assertEquals('Demos cant be more than 200MB in size', $this->uploadProvider->validateHeader(
|
||||
99999999999,
|
||||
new Header(
|
||||
'HL2DEMO',
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue