for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
/**
* ownCloud - foobar
*
* This file is licensed under the Affero General Public License version 3 or
* later. See the COPYING file.
* @author jus <[email protected]>
* @copyright jus 2016
*/
use OCP\AppFramework\App;
use Test\TestCase;
* This test shows how to make a small Integration Test. Query your class
* directly from the container, only pass in mocks if needed and run your tests
* against the database
class AppTest extends TestCase {
private $container;
public function setUp() {
parent::setUp();
$app = new App('apporder');
$this->container = $app->getContainer();
}
public function testAppInstalled() {
$appManager = $this->container->query('OCP\App\IAppManager');
$this->assertTrue($appManager->isInstalled('apporder'));