[BUGFIX] Fix PHP warnings in PackageManager 89/26789/4
authorMarkus Klein <klein.t3@mfc-linz.at>
Mon, 13 Jan 2014 19:49:40 +0000 (20:49 +0100)
committerStefan Neufeind <typo3.neufeind@speedpartner.de>
Mon, 13 Jan 2014 20:57:29 +0000 (21:57 +0100)
Resolves: #54963
Releases: 6.2
Change-Id: I58b1f6109872d6eb8059fceb1bec1af7134e84e2
Reviewed-on: https://review.typo3.org/26789
Reviewed-by: Markus Klein
Tested-by: Markus Klein
Reviewed-by: Thomas Maroschik
Tested-by: Thomas Maroschik
Reviewed-by: Stefan Neufeind
Tested-by: Stefan Neufeind
typo3/sysext/core/Classes/Package/PackageManager.php
typo3/sysext/extensionmanager/Tests/Unit/Service/ExtensionManagementServiceTest.php

index 6f3c219..cd92fe2 100644 (file)
@@ -793,6 +793,9 @@ class PackageManager extends \TYPO3\Flow\Package\PackageManager implements \TYPO
         * @return void
         */
        protected function resolvePackageDependencies() {
+               foreach ($this->packages as $packageKey => $package) {
+                       $this->packageStatesConfiguration['packages'][$packageKey]['dependencies'] = array();
+               }
                foreach ($this->activePackages as $packageKey => $package) {
                        $this->packageStatesConfiguration['packages'][$packageKey]['dependencies'] = $this->getDependencyArrayForPackage($packageKey);
                }
index 22dbf95..df2de76 100644 (file)
@@ -209,7 +209,7 @@ class ExtensionManagementServiceTest extends \TYPO3\CMS\Extbase\Tests\Unit\BaseT
                                'siteRelPath' => 'path'
                        )
                );
-               $installUtility = $this->getAccessibleMock('TYPO3\\CMS\\Extensionmanager\\Utility\\InstallUtility', array('install'), array(), '', FALSE);
+               $installUtility = $this->getAccessibleMock('TYPO3\\CMS\\Extensionmanager\\Utility\\InstallUtility', array('install','emitWillInstallExtensions'), array(), '', FALSE);
                $installUtility->expects($this->once())->method('install')->with(array(
                        'key' => 'foobar',
                        'siteRelPath' => 'path'
@@ -229,7 +229,7 @@ class ExtensionManagementServiceTest extends \TYPO3\CMS\Extbase\Tests\Unit\BaseT
                $installQueue = array(
                        'foobar' => 'foobar'
                );
-               $installUtility = $this->getAccessibleMock('TYPO3\\CMS\\Extensionmanager\\Utility\\InstallUtility', array('install'), array(), '', FALSE);
+               $installUtility = $this->getAccessibleMock('TYPO3\\CMS\\Extensionmanager\\Utility\\InstallUtility', array('install','emitWillInstallExtensions'), array(), '', FALSE);
                $installUtility->expects($this->once())->method('install')->with('foobar');
                $managementMock->_set('installUtility', $installUtility);
                $resolvedDependencies = $managementMock->_call('installDependencies', $installQueue);