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
74 changes: 74 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
name: Tests

on: [ push, pull_request ]

jobs:
tests:
name: Tests
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
php: [ '8.2', '8.3' ]
typo3: [ '12', '13' ]
composerInstall: [ 'composerInstallLowest', 'composerInstallHighest' ]
include:
- typo3: '12'
php: '8.1'
composerInstall: 'composerInstallLowest'
- typo3: '12'
php: '8.1'
composerInstall: 'composerInstallHighest'

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

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

- name: Install dependencies
run: Build/Scripts/runTests.sh -t ${{ matrix.typo3 }} -p ${{ matrix.php }} -s ${{ matrix.composerInstall }}

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

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

- name: CGL
run: Build/Scripts/runTests.sh -n -t ${{ matrix.typo3 }} -p ${{ matrix.php }} -s cgl -n

- name: PHPStan
run: Build/Scripts/runTests.sh -t ${{ matrix.typo3 }} -p ${{ matrix.php }} -s phpstan -e "--error-format=github"

#- name: Functional tests
#run: Build/Scripts/runTests.sh -t ${{ matrix.typo3 }} -p ${{ matrix.php }} -s functional

#- name: Unit tests
#run: Build/Scripts/runTests.sh -t ${{ matrix.typo3 }} -p ${{ matrix.php }} -s unit

#- name: Functional tests coverage
#if: matrix.php == '8.2' && matrix.typo3 == '13' && matrix.composerInstall == 'composerInstallHighest'
#run: Build/Scripts/runTests.sh -t ${{ matrix.typo3 }} -p ${{ matrix.php }} -s unit -x -e "--coverage-php=.Build/coverage/functional.cov"

#- name: Unit tests coverage
#if: matrix.php == '8.2' && matrix.typo3 == '13' && matrix.composerInstall == 'composerInstallHighest'
#run: Build/Scripts/runTests.sh -t ${{ matrix.typo3 }} -p ${{ matrix.php }} -s unit -x -e "--coverage-php=.Build/coverage/unit.cov"

#- name: Composer require phpunit/phpcov for merging the code coverage
#if: matrix.php == '8.2' && matrix.typo3 == '13' && matrix.composerInstall == 'composerInstallHighest'
#run: Build/Scripts/runTests.sh -t ${{ matrix.typo3 }} -p ${{ matrix.php }} -s composer require --dev phpunit/phpcov

#- name: Merge coverage
#if: matrix.php == '8.2' && matrix.typo3 == '13' && matrix.composerInstall == 'composerInstallHighest'
#run: ./.Build/bin/phpcov merge --clover=build/logs/clover.xml .Build/coverage

#- name: Upload coverage
#if: matrix.php == '8.2' && matrix.typo3 == '13' && matrix.composerInstall == 'composerInstallHighest'
#env:
#COVERALLS_REPO_TOKEN: ${{ secrets.GITHUB_TOKEN }}
#run: |
#composer global require php-coveralls/php-coveralls
#export PATH="$(composer config -g home)/vendor/bin:$PATH"
#php-coveralls --coverage_clover=build/logs/clover.xml -v
12 changes: 12 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
.idea
vendor
composer.lock
.php-cs-fixer.cache
.Build
Documentation-GENERATED-temp
/public
.phplint.cache
.cache
composer.json.testing
var
*.map
10 changes: 10 additions & 0 deletions .php-cs-fixer.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<?php

use PhpCsFixer\Runner\Parallel\ParallelConfigFactory;
use TYPO3\CodingStandards\CsFixerConfig;

$config = CsFixerConfig::create();
$config->setParallelConfig(ParallelConfigFactory::detect());

$config->getFinder()->in('Classes')->in('Configuration')->in('Tests');
return $config;
9 changes: 9 additions & 0 deletions Build/Scripts/renderDocumentation.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#!/bin/bash

# This file is meant to be run from the root of the repository.

docker run --rm --user=$(id -u):$(id -g) \
-v "$(pwd):/PROJECT" \
-v "$(pwd)/Documentation-GENERATED-temp:/RESULT" \
ghcr.io/t3docs/render-documentation:latest \
makehtml
Loading