Add new wrapper for TYPO3 issues

Issues sometimes contain a lot of code and text.
We will now handle them just like commits.
This commit is contained in:
Daniel Siepmann 2024-05-24 09:35:36 +02:00
parent 413dff9d46
commit e224e57dd6
Signed by: Daniel Siepmann
GPG key ID: 33D6629915560EF4
5 changed files with 338 additions and 0 deletions

View file

@ -3,6 +3,7 @@
use DanielSiepmann\FediverseFeedWrappers\RequestHandler;
use DanielSiepmann\FediverseFeedWrappers\WrapperRegistry;
use DanielSiepmann\FediverseFeedWrappers\Wrapper\DanielSiepmannTypo3;
use DanielSiepmann\FediverseFeedWrappers\Wrapper\ForgeTypo3Issues;
use DanielSiepmann\FediverseFeedWrappers\Wrapper\Frontpage;
use DanielSiepmann\FediverseFeedWrappers\Wrapper\GitHubTypo3;
@ -12,6 +13,7 @@ require_once __DIR__ . '/../vendor/autoload.php';
new WrapperRegistry([
'' => Frontpage::class,
'GitHubTypo3' => GitHubTypo3::class,
'ForgeTypo3Issues' => ForgeTypo3Issues::class,
'DanielSiepmannTypo3' => DanielSiepmannTypo3::class,
])
))->handleRequest();

View file

@ -0,0 +1,61 @@
<?php
declare(strict_types=1);
/*
* Copyright (C) 2023 Daniel Siepmann <coding@daniel-siepmann.de>
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
* 02110-1301, USA.
*/
namespace DanielSiepmann\FediverseFeedWrappers\Wrapper;
use DOMDocument;
use DanielSiepmann\FediverseFeedWrappers\WrapperInterface;
class ForgeTypo3Issues implements WrapperInterface
{
private string $url;
public function __construct(
string $url = 'https://forge.typo3.org/projects/typo3cms-core/issues.atom?c%5B%5D=status&c%5B%5D=priority&c%5B%5D=subject&c%5B%5D=category&c%5B%5D=fixed_version&c%5B%5D=done_ratio&f%5B%5D=status_id&f%5B%5D=&group_by=tracker&key=bc42963d07fee8c6960da7b7224225009d493c99&op%5Bstatus_id%5D==&set_filter=1&sort=id:desc,priority&t%5B%5D=&utf8=%E2%9C%93&v%5Bstatus_id%5D%5B%5D=1'
) {
$this->url = $url;
}
public function contentType(): string
{
return 'application/atom+xml';
}
/**
* We don't want the full message within each feed item.
*
* Interested people can head over to the actual URL for full info.
*/
public function content(): string
{
$content = new DOMDocument();
$content->loadXML(file_get_contents($this->url));
foreach ($content->getElementsByTagName('entry') as $entry) {
// Remove content (body in friendica), title will become body within friendica
$entry->getElementsByTagName('content')[0]->nodeValue = '';
}
return $content->saveXML();
}
}

View file

@ -0,0 +1,35 @@
<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
<title>TYPO3 Core: Issues</title>
<link rel="self" href="http://forge.typo3.org/projects/typo3cms-core/issues.atom?c%5B%5D=status&amp;c%5B%5D=priority&amp;c%5B%5D=subject&amp;c%5B%5D=category&amp;c%5B%5D=fixed_version&amp;c%5B%5D=done_ratio&amp;f%5B%5D=status_id&amp;f%5B%5D=&amp;group_by=tracker&amp;key=bc42963d07fee8c6960da7b7224225009d493c99&amp;op%5Bstatus_id%5D=%3D&amp;set_filter=1&amp;sort=id%3Adesc%2Cpriority&amp;t%5B%5D=&amp;utf8=%E2%9C%93&amp;v%5Bstatus_id%5D%5B%5D=1"/>
<link rel="alternate" href="http://forge.typo3.org/projects/typo3cms-core/issues?c%5B%5D=status&amp;c%5B%5D=priority&amp;c%5B%5D=subject&amp;c%5B%5D=category&amp;c%5B%5D=fixed_version&amp;c%5B%5D=done_ratio&amp;f%5B%5D=status_id&amp;f%5B%5D=&amp;group_by=tracker&amp;op%5Bstatus_id%5D=%3D&amp;set_filter=1&amp;sort=id%3Adesc%2Cpriority&amp;t%5B%5D=&amp;utf8=%E2%9C%93&amp;v%5Bstatus_id%5D%5B%5D=1"/>
<id>http://forge.typo3.org/</id>
<icon>http://forge.typo3.org/themes/typo3_forge/favicon/favicon.png?1705866169</icon>
<updated>2024-05-23T12:05:09Z</updated>
<author>
<name>TYPO3 Forge</name>
</author>
<generator uri="https://www.redmine.org/">
Redmine </generator>
<entry>
<title>Bug #103885 (New): foreign_match_fields is ignored in flexforms in Typo3 12</title>
<link rel="alternate" href="http://forge.typo3.org/issues/103885"/>
<id>http://forge.typo3.org/issues/103885</id>
<updated>2024-05-23T12:05:09Z</updated>
<author>
<name>Georgi Mateev</name>
</author>
<content type="html"></content>
</entry>
<entry>
<title>Bug #103883 (New): View generated in LinkBrowserController missed PageTS configuration</title>
<link rel="alternate" href="http://forge.typo3.org/issues/103883"/>
<id>http://forge.typo3.org/issues/103883</id>
<updated>2024-05-23T09:39:11Z</updated>
<author>
<name>Nicole Cordes</name>
<email>typo3@cordes.co</email>
</author>
<content type="html"></content>
</entry>
</feed>

View file

@ -0,0 +1,160 @@
<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
<title>TYPO3 Core: Issues</title>
<link rel="self" href="http://forge.typo3.org/projects/typo3cms-core/issues.atom?c%5B%5D=status&amp;c%5B%5D=priority&amp;c%5B%5D=subject&amp;c%5B%5D=category&amp;c%5B%5D=fixed_version&amp;c%5B%5D=done_ratio&amp;f%5B%5D=status_id&amp;f%5B%5D=&amp;group_by=tracker&amp;key=bc42963d07fee8c6960da7b7224225009d493c99&amp;op%5Bstatus_id%5D=%3D&amp;set_filter=1&amp;sort=id%3Adesc%2Cpriority&amp;t%5B%5D=&amp;utf8=%E2%9C%93&amp;v%5Bstatus_id%5D%5B%5D=1"/>
<link rel="alternate" href="http://forge.typo3.org/projects/typo3cms-core/issues?c%5B%5D=status&amp;c%5B%5D=priority&amp;c%5B%5D=subject&amp;c%5B%5D=category&amp;c%5B%5D=fixed_version&amp;c%5B%5D=done_ratio&amp;f%5B%5D=status_id&amp;f%5B%5D=&amp;group_by=tracker&amp;op%5Bstatus_id%5D=%3D&amp;set_filter=1&amp;sort=id%3Adesc%2Cpriority&amp;t%5B%5D=&amp;utf8=%E2%9C%93&amp;v%5Bstatus_id%5D%5B%5D=1"/>
<id>http://forge.typo3.org/</id>
<icon>http://forge.typo3.org/themes/typo3_forge/favicon/favicon.png?1705866169</icon>
<updated>2024-05-23T12:05:09Z</updated>
<author>
<name>TYPO3 Forge</name>
</author>
<generator uri="https://www.redmine.org/">
Redmine </generator>
<entry>
<title>Bug #103885 (New): foreign_match_fields is ignored in flexforms in Typo3 12</title>
<link rel="alternate" href="http://forge.typo3.org/issues/103885"/>
<id>http://forge.typo3.org/issues/103885</id>
<updated>2024-05-23T12:05:09Z</updated>
<author>
<name>Georgi Mateev</name>
</author>
<content type="html">
&lt;p&gt;The inline TCA type (also tested for the new file type) does not respect the configuration foreign_match_fields.fieldname when in Flexform context. Up to TYPO3 v11 it would respect it and store the value in the sys_file_reference table. After updating to TYPO3 v12 it does not respect it anymore and writes the name of the TCA Field instead.&lt;/p&gt;
&lt;p&gt;Example:&lt;br /&gt;&lt;pre&gt;&lt;code class="xml syntaxhl" data-language="xml"&gt;&lt;span class="nt"&gt;&amp;lt;settings.thumbnailImages&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;label&amp;gt;&lt;/span&gt;LLL:EXT:sg_vimeo/Resources/Private/Language/locallang.xlf:flexform.thumbnailImages
&lt;span class="nt"&gt;&amp;lt;/label&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;description&amp;gt;&lt;/span&gt;
LLL:EXT:sg_vimeo/Resources/Private/Language/locallang.xlf:flexform.thumbnailImages.description
&lt;span class="nt"&gt;&amp;lt;/description&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;config&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;type&amp;gt;&lt;/span&gt;inline&lt;span class="nt"&gt;&amp;lt;/type&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;foreign_table&amp;gt;&lt;/span&gt;sys_file_reference&lt;span class="nt"&gt;&amp;lt;/foreign_table&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;foreign_field&amp;gt;&lt;/span&gt;uid_foreign&lt;span class="nt"&gt;&amp;lt;/foreign_field&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;foreign_table_field&amp;gt;&lt;/span&gt;tablenames&lt;span class="nt"&gt;&amp;lt;/foreign_table_field&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;foreign_label&amp;gt;&lt;/span&gt;uid_local&lt;span class="nt"&gt;&amp;lt;/foreign_label&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;foreign_sortby&amp;gt;&lt;/span&gt;sorting_foreign&lt;span class="nt"&gt;&amp;lt;/foreign_sortby&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;foreign_selector&amp;gt;&lt;/span&gt;uid_local&lt;span class="nt"&gt;&amp;lt;/foreign_selector&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;foreign_selector_fieldTcaOverride&lt;/span&gt; &lt;span class="na"&gt;type=&lt;/span&gt;&lt;span class="s"&gt;"array"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;config&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;appearance&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;elementBrowserType&amp;gt;&lt;/span&gt;file&lt;span class="nt"&gt;&amp;lt;/elementBrowserType&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;elementBrowserAllowed&amp;gt;&lt;/span&gt;jpg,png,svg,jpeg,gif,webp&lt;span class="nt"&gt;&amp;lt;/elementBrowserAllowed&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/appearance&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/config&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/foreign_selector_fieldTcaOverride&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;foreign_match_fields&lt;/span&gt; &lt;span class="na"&gt;type=&lt;/span&gt;&lt;span class="s"&gt;"array"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;fieldname&amp;gt;&lt;/span&gt;tx_sgvimeo_thumbnail_image&lt;span class="nt"&gt;&amp;lt;/fieldname&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/foreign_match_fields&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;filter&lt;/span&gt; &lt;span class="na"&gt;type=&lt;/span&gt;&lt;span class="s"&gt;"array"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;userFunc&amp;gt;&lt;/span&gt;TYPO3\CMS\Core\Resource\Filter\FileExtensionFilter-&amp;gt;filterInlineChildren
&lt;span class="nt"&gt;&amp;lt;/userFunc&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;parameters&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;allowedFileExtensions&amp;gt;&lt;/span&gt;jpg,png,svg,jpeg,gif,webp&lt;span class="nt"&gt;&amp;lt;/allowedFileExtensions&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;disallowedFileExtensions&amp;gt;&amp;lt;/disallowedFileExtensions&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/parameters&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/filter&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;appearance&lt;/span&gt; &lt;span class="na"&gt;type=&lt;/span&gt;&lt;span class="s"&gt;"array"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;useSortable&amp;gt;&lt;/span&gt;1&lt;span class="nt"&gt;&amp;lt;/useSortable&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;headerThumbnail&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;field&amp;gt;&lt;/span&gt;uid_local&lt;span class="nt"&gt;&amp;lt;/field&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;height&amp;gt;&lt;/span&gt;45m&lt;span class="nt"&gt;&amp;lt;/height&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/headerThumbnail&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;enabledControls&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;info&amp;gt;&lt;/span&gt;1&lt;span class="nt"&gt;&amp;lt;/info&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;new&amp;gt;&lt;/span&gt;0&lt;span class="nt"&gt;&amp;lt;/new&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;dragdrop&amp;gt;&lt;/span&gt;1&lt;span class="nt"&gt;&amp;lt;/dragdrop&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;sort&amp;gt;&lt;/span&gt;1&lt;span class="nt"&gt;&amp;lt;/sort&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;hide&amp;gt;&lt;/span&gt;1&lt;span class="nt"&gt;&amp;lt;/hide&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;delete&amp;gt;&lt;/span&gt;1&lt;span class="nt"&gt;&amp;lt;/delete&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/enabledControls&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/appearance&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;overrideChildTca&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;columns&lt;/span&gt; &lt;span class="na"&gt;type=&lt;/span&gt;&lt;span class="s"&gt;"array"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;uid_local&lt;/span&gt; &lt;span class="na"&gt;type=&lt;/span&gt;&lt;span class="s"&gt;"array"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;config&lt;/span&gt; &lt;span class="na"&gt;type=&lt;/span&gt;&lt;span class="s"&gt;"array"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;appearance&lt;/span&gt; &lt;span class="na"&gt;type=&lt;/span&gt;&lt;span class="s"&gt;"array"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;elementBrowserType&amp;gt;&lt;/span&gt;file&lt;span class="nt"&gt;&amp;lt;/elementBrowserType&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;elementBrowserAllowed&amp;gt;&lt;/span&gt;jpg,png,svg,jpeg,gif&lt;span class="nt"&gt;&amp;lt;/elementBrowserAllowed&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/appearance&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/config&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/uid_local&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;crop&lt;/span&gt; &lt;span class="na"&gt;type=&lt;/span&gt;&lt;span class="s"&gt;"array"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;config&lt;/span&gt; &lt;span class="na"&gt;type=&lt;/span&gt;&lt;span class="s"&gt;"array"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;cropVariants&lt;/span&gt; &lt;span class="na"&gt;type=&lt;/span&gt;&lt;span class="s"&gt;"array"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;medium&lt;/span&gt; &lt;span class="na"&gt;type=&lt;/span&gt;&lt;span class="s"&gt;"array"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;disabled&amp;gt;&lt;/span&gt;1&lt;span class="nt"&gt;&amp;lt;/disabled&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/medium&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;small&lt;/span&gt; &lt;span class="na"&gt;type=&lt;/span&gt;&lt;span class="s"&gt;"array"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;disabled&amp;gt;&lt;/span&gt;1&lt;span class="nt"&gt;&amp;lt;/disabled&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/small&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;extrasmall&lt;/span&gt; &lt;span class="na"&gt;type=&lt;/span&gt;&lt;span class="s"&gt;"array"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;disabled&amp;gt;&lt;/span&gt;1&lt;span class="nt"&gt;&amp;lt;/disabled&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/extrasmall&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/cropVariants&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/config&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/crop&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/columns&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;types&lt;/span&gt; &lt;span class="na"&gt;type=&lt;/span&gt;&lt;span class="s"&gt;"array"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;numIndex&lt;/span&gt; &lt;span class="na"&gt;index=&lt;/span&gt;&lt;span class="s"&gt;"2"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;showitem&amp;gt;&lt;/span&gt;
--palette--;LLL:EXT:lang/locallang_tca.xlf:sys_file_reference.imageoverlayPalette;imageoverlayPalette,--palette--;;filePalette
&lt;span class="nt"&gt;&amp;lt;/showitem&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/numIndex&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/types&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/overrideChildTca&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/config&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/settings.thumbnailImages&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;Expected result in the database:&lt;br /&gt;tx_sgvimeo_thumbnail_image&lt;/p&gt;
&lt;p&gt;Actual result in the database:&lt;br /&gt;settings.thumbnailImages&lt;/p&gt;
&lt;p&gt;You can test this with our sgalinski/sg-vimeo extension in version 7.1.11 when trying to set a custom thumbnail image.&lt;/p&gt;
&lt;p&gt;This looks like a bug in TYPO3 12 or an undocumented breaking change.&lt;/p&gt; </content>
</entry>
<entry>
<title>Bug #103883 (New): View generated in LinkBrowserController missed PageTS configuration</title>
<link rel="alternate" href="http://forge.typo3.org/issues/103883"/>
<id>http://forge.typo3.org/issues/103883</id>
<updated>2024-05-23T09:39:11Z</updated>
<author>
<name>Nicole Cordes</name>
<email>typo3@cordes.co</email>
</author>
<content type="html">
&lt;p&gt;Given:&lt;/p&gt;
&lt;p&gt;- a package having following files:&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Configuration/page.tsconfig&lt;/strong&gt; with content &lt;em&gt;templates.typo3/cms-backend.123 = EXT:foo/Resources/Private/TemplateOverrides&lt;/em&gt; &lt;br /&gt;&lt;strong&gt;Resources/Private/TemplateOverrides/Templates/LinkBrowser/Page.html&lt;/strong&gt; with content &lt;em&gt;Foo&lt;/em&gt;&lt;br /&gt;&lt;strong&gt;Configuration/PageTs/PageTs.typoscript&lt;/strong&gt; with content &lt;em&gt;templates.typo3/cms-backend.123 &gt;&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;The given PageTS is used on the root page (in page settings).&lt;/p&gt;
&lt;p&gt;Expectation:&lt;/p&gt;
&lt;p&gt;- LinkBrowser in Redirect record (pageUid = 0) shows "Foo" in the page browser as the overrides template is used&lt;br /&gt;- any other LinkBrowser (in page context) shows default page tree in browser&lt;/p&gt;
&lt;p&gt;Actual:&lt;/p&gt;
&lt;p&gt;- the reset of the overrides template isn't triggered. "Foo" is always shown.&lt;/p&gt;
&lt;p&gt;The view is rendered in typo3/cms-backend/Classes/View/BackendViewFactory.php:73 expecting an "id" parameter in the request. This parameter isn't available in a "wizard/link/browse" context as the page id is provided in P[pid]=161 parameter&lt;/p&gt; </content>
</entry>
</feed>

View file

@ -0,0 +1,80 @@
<?php
declare(strict_types=1);
/*
* Copyright (C) 2024 Daniel Siepmann <coding@daniel-siepmann.de>
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
* 02110-1301, USA.
*/
namespace DanielSiepmann\FediverseFeedWrappers\Tests\Unit\Wrapper;
use DanielSiepmann\FediverseFeedWrappers\WrapperInterface;
use DanielSiepmann\FediverseFeedWrappers\Wrapper\ForgeTypo3Issues;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\Attributes\Test;
use PHPUnit\Framework\TestCase;
#[CoversClass(ForgeTypo3Issues::class)]
final class ForgeTypo3IssuesTest extends TestCase
{
#[Test]
public function canBeCreated(): void
{
$subject = new ForgeTypo3Issues();
self::assertInstanceOf(
ForgeTypo3Issues::class,
$subject
);
}
#[Test]
public function isInstanceOfWrapperInterface(): void
{
$subject = new ForgeTypo3Issues();
self::assertInstanceOf(
WrapperInterface::class,
$subject
);
}
#[Test]
public function returnsContentType(): void
{
$subject = new ForgeTypo3Issues();
self::assertSame(
'application/atom+xml',
$subject->contentType()
);
}
#[Test]
public function returnsAdjustedFeed(): void
{
$subject = new ForgeTypo3Issues(
__DIR__ . '/Fixtures/ForgeTypo3Issues.atom'
);
self::assertStringEqualsFile(
__DIR__ . '/Assertions/ForgeTypo3Issues.atom',
$subject->content()
);
}
}