Skip to content
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
71 changes: 25 additions & 46 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,56 +1,35 @@
# Adapted from https://github.com/TYPO3GmbH/blog/blob/master/.github/workflows/ci.yml
name: CI
name: Tests

on: [pull_request]

jobs:
build:
testing:
name: Testing

runs-on: ubuntu-latest

strategy:
fail-fast: false
fail-fast: true

matrix:
typo3: ['^11.5', '^12.4']
php: ['8.1']
include:
- typo3: ^11.5
php: '7.4'
- typo3: ^11.5
php: '8.0'
- typo3: ^12.4
php: '8.2'
php:
- '8.2'

steps:
- name: Checkout
uses: actions/checkout@v2

- name: Setup PHP ${{ matrix.php }}, with composer and extensions
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
extensions: mbstring, dom, zip

- name: Validate composer.json and composer.lock
run: composer validate

- name: Get composer cache directory
id: composer-cache
run: echo "::set-output name=dir::$(composer config cache-files-dir)"

- name: Cache composer dependencies
uses: actions/cache@v2
with:
path: ${{ steps.composer-cache.outputs.dir }}
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }}
restore-keys: ${{ runner.os }}-composer-

- name: Install dependencies with typo3/cms-core:${{ matrix.typo3 }}
run: |
composer require typo3/cms-core:${{ matrix.typo3 }} --no-progress
git checkout composer.json

- name: Lint PHP
run: composer ci:php:lint

- name: php-cs-fixer
run: composer ci:php:fixer
- name: 'Checkout'
uses: actions/checkout@v4

- name: 'Lint PHP'
run: Build/Scripts/runTests.sh -p ${{ matrix.php }} -s lint

- name: 'Install testing system'
run: Build/Scripts/runTests.sh -p ${{ matrix.php }} -s composerUpdate

- name: 'Composer validate'
run: Build/Scripts/runTests.sh -p ${{ matrix.php }} -s composerValidate

- name: 'Composer normalize'
run: Build/Scripts/runTests.sh -p ${{ matrix.php }} -s composerNormalize -n

- name: 'CGL'
run: Build/Scripts/runTests.sh -n -p ${{ matrix.php }} -s cgl
65 changes: 53 additions & 12 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,36 +1,77 @@
########################
# dropbox
# global ignore file
# ignore file for
# EXT:dropbox
########################

# Ignore files generated by docs rendering
*GENERATED*
/docker-compose.yaml
/docker-compose.yml

#
# Don't ignore .rej and .orig as we want to see/clean files after conflict resolution.
#
# For local exclude patterns please edit .git/info/exclude.
#
########################
#
# Ignore temporary files (left by editors and OS)
*~
*.bak
*.swp
.DS_Store

#
# Ignore by common IDEs used directories/files
nbproject
*.idea
*.project
*.vscode
.buildpath
.settings
.TemporaryItems
.webprj
.fleet

#
# Temporary files and folders
/.cache
.php_cs.cache
.php-cs-fixer.cache
.sass-cache
.session
*.log

#
# Ignore build stuff
/.ddev/*
/Build/.auth
/Build/.cache
/Build/phpunit/FunctionalTests-Job-*
/Build/bower_components/*
/Build/node_modules/*
/Build/JavaScript
!/Build/typings/no-def*
/Build/testing-docker/local/.env
/Build/testing-docker/local/macos_passwd
/typo3/sysext/*/Resources/Private/TypeScript/*.js
/typo3/sysext/*/Resources/Public/JavaScript/*.js.map
/typo3/sysext/core/Tests/AcceptanceTests-Job-*
#
# TypeScript stuff
.baseDir.ts
.tscache
#
# Ignore composer stuff
/composer.lock
/bin/*
/vendor/*
/index.php
/typo3/install.php
#
# Ignore common TYPO3 CMS files/directories
/typo3temp/*
/typo3conf/*
!/typo3conf/ext
/typo3conf/ext/*
/fileadmin/*
/uploads/*
/FIRST_INSTALL
#
# root .htaccess file
/.htaccess
# Ignore files generated by tests
typo3/sysext/core/Tests/Acceptance/Support/_generated/
/favicon.ico
# Ignore files generated by docs rendering
Documentation-GENERATED-temp/
153 changes: 153 additions & 0 deletions .phpstorm.meta.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,153 @@
<?php

/**
* Extend PhpStorms code completion capabilities by providing a meta file
*
* @link https://www.jetbrains.com/help/phpstorm/ide-advanced-metadata.html
*/

namespace PHPSTORM_META {
expectedArguments(
\TYPO3\CMS\Core\Context\Context::getAspect(),
0,
'date',
'visibility',
'backend.user',
'frontend.user',
'workspace',
'language',
'frontend.preview',
);
override(\TYPO3\CMS\Core\Context\Context::getAspect(), map([
'date' => \TYPO3\CMS\Core\Context\DateTimeAspect::class,
'visibility' => \TYPO3\CMS\Core\Context\VisibilityAspect::class,
'backend.user' => \TYPO3\CMS\Core\Context\UserAspect::class,
'frontend.user' => \TYPO3\CMS\Core\Context\UserAspect::class,
'workspace' => \TYPO3\CMS\Core\Context\WorkspaceAspect::class,
'language' => \TYPO3\CMS\Core\Context\LanguageAspect::class,
'frontend.preview' => \TYPO3\CMS\Frontend\Context\PreviewAspect::class,
]));
expectedArguments(
\TYPO3\CMS\Core\Context\DateTimeAspect::get(),
0,
'timestamp',
'iso',
'timezone',
'full',
'accessTime'
);
expectedArguments(
\TYPO3\CMS\Core\Context\VisibilityAspect::get(),
0,
'includeHiddenPages',
'includeHiddenContent',
'includeDeletedRecords'
);
expectedArguments(
\TYPO3\CMS\Core\Context\UserAspect::get(),
0,
'id',
'username',
'isLoggedIn',
'isAdmin',
'groupIds',
'groupNames'
);
expectedArguments(
\TYPO3\CMS\Core\Context\WorkspaceAspect::get(),
0,
'id',
'isLive',
'isOffline'
);
expectedArguments(
\TYPO3\CMS\Core\Context\LanguageAspect::get(),
0,
'id',
'contentId',
'fallbackChain',
'overlayType',
'legacyLanguageMode',
'legacyOverlayType'
);
expectedArguments(
\TYPO3\CMS\Frontend\Context\PreviewAspect::get(),
0,
'isPreview'
);

expectedArguments(
\Psr\Http\Message\ServerRequestInterface::getAttribute(),
0,
'frontend.user',
'normalizedParams',
'site',
'language',
'routing',
'module',
'moduleData',
'frontend.controller',
'frontend.typoscript',
'frontend.cache.collector',
'frontend.cache.instruction',
'frontend.page.information',
);
override(\Psr\Http\Message\ServerRequestInterface::getAttribute(), map([
'frontend.user' => \TYPO3\CMS\Frontend\Authentication\FrontendUserAuthentication::class,
'normalizedParams' => \TYPO3\CMS\Core\Http\NormalizedParams::class,
'site' => \TYPO3\CMS\Core\Site\Entity\SiteInterface::class,
'language' => \TYPO3\CMS\Core\Site\Entity\SiteLanguage::class,
'routing' => '\TYPO3\CMS\Core\Routing\SiteRouteResult|\TYPO3\CMS\Core\Routing\PageArguments',
'module' => \TYPO3\CMS\Backend\Module\ModuleInterface::class,
'moduleData' => \TYPO3\CMS\Backend\Module\ModuleData::class,
'frontend.controller' => \TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::class,
'frontend.typoscript' => \TYPO3\CMS\Core\TypoScript\FrontendTypoScript::class,
'frontend.cache.collector' => \TYPO3\CMS\Core\Cache\CacheDataCollector::class,
'frontend.cache.instruction' => \TYPO3\CMS\Frontend\Cache\CacheInstruction::class,
'frontend.page.information' => \TYPO3\CMS\Frontend\Page\PageInformation::class,
]));

expectedArguments(
\TYPO3\CMS\Core\Http\ServerRequest::getAttribute(),
0,
'frontend.user',
'normalizedParams',
'site',
'language',
'routing',
'module',
'moduleData'
);
override(\TYPO3\CMS\Core\Http\ServerRequest::getAttribute(), map([
'frontend.user' => \TYPO3\CMS\Frontend\Authentication\FrontendUserAuthentication::class,
'normalizedParams' => \TYPO3\CMS\Core\Http\NormalizedParams::class,
'site' => \TYPO3\CMS\Core\Site\Entity\SiteInterface::class,
'language' => \TYPO3\CMS\Core\Site\Entity\SiteLanguage::class,
'routing' => '\TYPO3\CMS\Core\Routing\SiteRouteResult|\TYPO3\CMS\Core\Routing\PageArguments',
'module' => \TYPO3\CMS\Backend\Module\ModuleInterface::class,
'moduleData' => \TYPO3\CMS\Backend\Module\ModuleData::class,
]));

override(\TYPO3\CMS\Core\Routing\SiteMatcher::matchRequest(), type(
\TYPO3\CMS\Core\Routing\SiteRouteResult::class,
\TYPO3\CMS\Core\Routing\RouteResultInterface::class,
)
);

override(\TYPO3\CMS\Core\Routing\PageRouter::matchRequest(), type(
\TYPO3\CMS\Core\Routing\PageArguments::class,
\TYPO3\CMS\Core\Routing\RouteResultInterface::class,
));

override(\Psr\Container\ContainerInterface::get(0), map([
'' => '@',
]));

override(\Psr\EventDispatcher\EventDispatcherInterface::dispatch(0), map([
'' => '@',
]));

override(\TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance(0), map([
'' => '@'
]));
}
Loading