feat: Namespace FriendsOfREDAXO/ActivityLog, Bugfixes & Dependency-Updates (v1.0.0-beta1) #47
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: PHP checks | |
| on: | |
| push: | |
| branches: [ master ] | |
| pull_request: | |
| branches: [ master ] | |
| permissions: | |
| contents: read | |
| jobs: | |
| phpunit: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup PHP | |
| uses: shivammathur/setup-php@v2 | |
| with: | |
| php-version: '8.4' | |
| extensions: gd, intl, pdo_mysql | |
| coverage: none | |
| - name: Download latest REDAXO release | |
| run: | | |
| LATEST_RELEASE=$(curl -L -s -H 'Accept: application/json' https://github.com/redaxo/redaxo/releases/latest) | |
| REDAXO_VERSION=$(echo $LATEST_RELEASE | sed -e 's/.*"tag_name":"\([^"]*\)".*/\1/') | |
| echo "Downloaded REDAXO $REDAXO_VERSION" | |
| curl -Ls -o redaxo.zip https://github.com/redaxo/redaxo/releases/download/$REDAXO_VERSION/redaxo_$REDAXO_VERSION.zip | |
| unzip -oq redaxo.zip -d redaxo_cms | |
| rm redaxo.zip | |
| - name: Init database | |
| run: | | |
| sudo /etc/init.d/mysql start | |
| mysql -uroot -h127.0.0.1 -proot -e 'create database redaxo5;' | |
| - name: Setup REDAXO | |
| run: | | |
| php redaxo_cms/redaxo/bin/console setup:run -n --lang=de_de --agree-license \ | |
| --db-host=127.0.0.1 --db-name=redaxo5 --db-password=root \ | |
| --db-createdb=no --db-setup=normal \ | |
| --admin-username=admin --admin-password=adminpassword \ | |
| --error-email=test@redaxo.invalid --ansi | |
| php redaxo_cms/redaxo/bin/console config:set --type boolean debug.enabled true | |
| php redaxo_cms/redaxo/bin/console config:set --type boolean debug.throw_always_exception true | |
| - name: Copy and install Addon | |
| run: | | |
| rsync -av --exclude='vendor' --exclude='.github' --exclude='.git' --exclude='redaxo_cms' \ | |
| './' 'redaxo_cms/redaxo/src/addons/${{ github.event.repository.name }}' | |
| redaxo_cms/redaxo/bin/console package:install 'phpmailer' | |
| redaxo_cms/redaxo/bin/console package:install '${{ github.event.repository.name }}' | |
| - name: Install test dependencies | |
| working-directory: redaxo_cms/redaxo/src/addons/${{ github.event.repository.name }} | |
| run: composer install --prefer-dist --no-progress --no-scripts | |
| - name: Setup Problem Matchers for PHPUnit | |
| run: echo "::add-matcher::${{ runner.tool_cache }}/phpunit.json" | |
| - name: Run phpunit | |
| working-directory: redaxo_cms/redaxo/src/addons/${{ github.event.repository.name }} | |
| run: composer test |