Skip to content
This repository has been archived by the owner on Dec 9, 2023. It is now read-only.

[BUGFIX] Fix the PHAR inclusion in TYPO3 8.7.17 #60

Merged
merged 1 commit into from
Jul 18, 2018
Merged
Show file tree
Hide file tree
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
1 change: 0 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ env:
- DATABASE_USER=travis DATABASE_HOST=localhost DATABASE_PORT=3306 DATABASE_NAME=typo3 DATABASE_PASSWORD=''
- TYPO3_PATH_ROOT=$PWD/.Build/public
matrix:
- TYPO3_VERSION="^7.6" RUN_TESTS_COMMAND=".Build/public/typo3/cli_dispatch.phpsh phpunit"
- TYPO3_VERSION="^8.7" RUN_TESTS_COMMAND=".Build/vendor/bin/typo3 phpunit:run"

matrix:
Expand Down
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ This project adheres to [Semantic Versioning](https://semver.org/).
- Remove the obsolete ext_autoload.php (#56)

### Fixed
- Fix the PHAR inclusion in TYPO3 8.7.17 (#59, #60)
- Only include the PHAR from the test runners (#57, #53)
- Use the DB name from the connection pool in TYPO3 >= 8.7 (#58, #55)
- Hide the test tables from BE user table permission lists (#52)
Expand Down
2 changes: 1 addition & 1 deletion Classes/BackEnd/Module.php
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ protected function translate($key)
*/
public function main()
{
require_once __DIR__ . '/../../Resources/Private/Libraries/phpunit-library.phar';
require_once PATH_site . 'typo3conf/ext/phpunit/Resources/Private/Libraries/phpunit-library.phar';

$this->doc = GeneralUtility::makeInstance(DocumentTemplate::class);
$this->doc->backPath = $GLOBALS['BACK_PATH'];
Expand Down
2 changes: 1 addition & 1 deletion Classes/TestRunner/CliTestRunner.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ public function run()
// This is needed as the configuration might include closures which cannot be backed up
$globalBackup = $this->removeClosures($GLOBALS['TYPO3_CONF_VARS']);

require_once __DIR__ . '/../../Resources/Private/Libraries/phpunit-library.phar';
require_once PATH_site . 'typo3conf/ext/phpunit/Resources/Private/Libraries/phpunit-library.phar';

// Run unit tests
/** @var string */
Expand Down
3 changes: 3 additions & 0 deletions Documentation/UsersManual/Installation/Index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,9 @@ These are basic requirements for using this extension:
#. View the extension's options in the Extension Manager and save them at
least once.

Please note that this extension will only work if it is installed directly
in typo3conf/ext/phpunit/. If it is symlinked, the PHAR inclusion will fail.

If you would like to run the unit tests of the phpunit extension
itself, you'll also need to install the following dummy extension
which are located in EXT:phpunit/TestExtensions/:
Expand Down