- fix: add constructor
- test
This commit is contained in:
1 parent
5febe2c27a
commit
2703773fe1
2 files changed
+27
No files matched your search
@@ -0,0 +1,23 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace OCA\AToCal\Tests\Unit\AppInfo;
|
||||
|
||||
use OCA\AToCal\AppInfo\Application;
|
||||
use PHPUnit\Framework\TestCase;
|
||||
use ReflectionMethod;
|
||||
|
||||
class ApplicationTest extends TestCase
|
||||
{
|
||||
public function testSupportsZeroArgumentConstruction(): void {
|
||||
/*
|
||||
* The server container instantiates the app class without arguments,
|
||||
* see ServerContainer::getAppContainer(). The app class must pass the
|
||||
* app id to App::__construct() itself.
|
||||
*/
|
||||
$constructor = new ReflectionMethod(Application::class, '__construct');
|
||||
|
||||
$this->assertSame(0, $constructor->getNumberOfRequiredParameters());
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user