Skip to content

Commit

Permalink
[BUGFIX] Fix failing tests in 9.5 branch
Browse files Browse the repository at this point in the history
minor package updates:
	composer require typo3fluid/fluid:^2.6.8 -> 2.6.6 to 2.6.8
	composer update mikey179/vfsStream 1.6.5 to 1.6.8
	composer require typo3/testing-framework:^4.14

Resolves: #89855
Releases: 9.5
Change-Id: I43c2b040d6d511451f3904d743ffbde60b1a6022
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/62529
Reviewed-by: Oliver Hader <oliver.hader@typo3.org>
Reviewed-by: Anja Leichsenring <aleichsenring@ab-softlab.de>
Reviewed-by: Susanne Moog <look@susi.dev>
Tested-by: Anja Leichsenring <aleichsenring@ab-softlab.de>
Tested-by: TYPO3com <noreply@typo3.com>
Tested-by: Susanne Moog <look@susi.dev>
  • Loading branch information
bmack authored and susannemoog committed Dec 5, 2019
1 parent 2556775 commit e959215
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 7 deletions.
2 changes: 1 addition & 1 deletion Classes/Html/RteHtmlParser.php
Original file line number Diff line number Diff line change
Expand Up @@ -1223,7 +1223,7 @@ protected function TS_AtagToAbs($value)
list($attribArray) = $this->get_tag_attributes($this->getFirstTag($v), true);
// Checking if there is a scheme, and if not, prepend the current url.
// ONLY do this if href has content - the <a> tag COULD be an anchor and if so, it should be preserved...
if ($attribArray['href'] !== '') {
if (($attribArray['href'] ?? '') !== '') {
$uP = parse_url(strtolower($attribArray['href']));
if (!$uP['scheme']) {
$attribArray['href'] = GeneralUtility::getIndpEnv('TYPO3_SITE_URL') . $attribArray['href'];
Expand Down
6 changes: 2 additions & 4 deletions Tests/Unit/Html/RteHtmlParserTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -659,8 +659,7 @@ public static function anchorCorrectlyTransformedOnWayToDatabaseProvider()
*/
public function anchorCorrectlyTransformedOnWayToDatabase($content, $expectedResult)
{
$eventDispatcher = $this->createMock(EventDispatcherInterface::class);
$subject = new RteHtmlParser($eventDispatcher);
$subject = new RteHtmlParser();
$thisConfig = ['proc.' => $this->procOptions];
self::assertEquals($expectedResult, $subject->RTE_transform($content, [], 'db', $thisConfig));
}
Expand Down Expand Up @@ -698,8 +697,7 @@ public static function anchorCorrectlyTransformedOnWayToDatabaseAndBackToRTEProv
*/
public function anchorCorrectlyTransformedOnWayToDatabaseAndBackToRTE($content, $expectedResult)
{
$eventDispatcher = $this->createMock(EventDispatcherInterface::class);
$subject = new RteHtmlParser($eventDispatcher);
$subject = new RteHtmlParser();
$thisConfig = ['proc.' => $this->procOptions];
self::assertEquals($expectedResult, $subject->RTE_transform($subject->RTE_transform($content, [], 'db', $thisConfig), [], 'rte', $thisConfig));
}
Expand Down
4 changes: 2 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -45,14 +45,14 @@
"typo3/cms-cli": "^2.0",
"typo3/cms-composer-installers": "^2.0",
"typo3/phar-stream-wrapper": "^3.1.3",
"typo3fluid/fluid": "^2.6.1"
"typo3fluid/fluid": "^2.6.8"
},
"require-dev": {
"codeception/codeception": "^2.5.4",
"fiunchinho/phpunit-randomizer": "^4.0",
"friendsofphp/php-cs-fixer": "^2.16.1",
"typo3/cms-styleguide": "~9.2.2",
"typo3/testing-framework": "~4.12.0"
"typo3/testing-framework": "^4.14"
},
"suggest": {
"ext-fileinfo": "Used for proper file type detection in the file abstraction layer",
Expand Down

0 comments on commit e959215

Please sign in to comment.