Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
chore(tests): cleanup bootstrap.php to be forward-compatible
Signed-off-by: Richard Steinmetz <[email protected]>
  • Loading branch information
st3iny committed Jun 10, 2025
commit f07dc353effca20086115cb781eff340ef0de169
12 changes: 9 additions & 3 deletions tests/php/unit/bootstrap.php
Original file line number Diff line number Diff line change
@@ -1,17 +1,23 @@
<?php

declare(strict_types=1);

/**
* SPDX-FileCopyrightText: 2019 Nextcloud GmbH and Nextcloud contributors
* SPDX-License-Identifier: AGPL-3.0-or-later
*/

if (!defined('PHPUNIT_RUN')) {
define('PHPUNIT_RUN', 1);
}

require_once __DIR__ . '/../../../../../lib/base.php';
use OCP\App\IAppManager;
use OCP\Server;

\OC::$composerAutoloader->addPsr4('Test\\', OC::$SERVERROOT . '/tests/lib/', true);
require_once __DIR__ . '/../../../../../lib/base.php';
require_once __DIR__ . '/../../../../../tests/autoload.php';
require_once __DIR__ . '/../../../vendor/autoload.php';

\OC_App::loadApp('calendar');
Server::get(IAppManager::class)->loadApp('calendar');

OC_Hook::clear();
Loading