Skip to content

Bump actions/download-artifact from 2 to 4.1.7 in /.github/workflows #296

Bump actions/download-artifact from 2 to 4.1.7 in /.github/workflows

Bump actions/download-artifact from 2 to 4.1.7 in /.github/workflows #296

Workflow file for this run

name: Test
on:
pull_request:
branches: ["main"]
push:
branches: ["main"]
jobs:
checkout:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Zip
run: zip -r repository.zip .
- name: Repository
uses: actions/upload-artifact@v2
with:
name: repository
path: repository.zip
test:
needs: checkout
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
php_version:
- "8.0"
- "8.1"
- "8.2"
include:
- php_version: "8.0"
artifact: true
# - php_version: "8.2.0RC3"
# experimental: true
# composer_platform_php: "8.0.24" # Use Latest PHP 8.0
steps:
- name: Checkout
uses: actions/download-artifact@v4.1.7
with:
name: repository
- name: Unzip
run: unzip repository.zip && rm -f repository.zip
- name: Prepare
run: |
echo UID=`id -u` >> $GITHUB_ENV
echo GID=`id -g` >> $GITHUB_ENV
- name: Build
run: docker-compose build
env:
PHP_VERSION: ${{ matrix.php_version }}
continue-on-error: ${{ matrix.experimental == true }}
- name: PHP Experimental
if: matrix.experimental == true
run: |
docker-compose run romans composer config platform.php ${{ matrix.composer_platform_php }}
docker-compose run romans composer update --lock --no-install
git diff composer.json composer.lock
continue-on-error: ${{ matrix.experimental == true }}
- name: Install
run: docker-compose run romans composer install
continue-on-error: ${{ matrix.experimental == true }}
- name: Test
run: docker-compose run -e COVERAGE_OPTIONS romans composer test
env:
COVERAGE_OPTIONS: --coverage-text --coverage-html build/coverage --coverage-clover build/coverage.xml
continue-on-error: ${{ matrix.experimental == true }}
- name: Package
run: docker-compose run romans composer archive --dir build --format zip --file package
continue-on-error: ${{ matrix.experimental == true }}
- name: Package Check
run: ./.github/bin/package-check.sh
continue-on-error: ${{ matrix.experimental == true }}
- name: Clean
run: docker-compose down
if: always()
- name: Zip
run: zip -r repository.zip .
if: matrix.artifact == true
- name: Repository
uses: actions/upload-artifact@v2
if: matrix.artifact == true
with:
name: repository
path: repository.zip
reports:
needs: test
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/download-artifact@v4.1.7
with:
name: repository
- name: Unzip
run: unzip repository.zip && rm -f repository.zip
- name: Coverage
uses: actions/upload-artifact@v2
with:
name: coverage
path: build/coverage/
- name: Package
uses: actions/upload-artifact@v2
with:
name: package
path: build/package.zip
- name: Codecov
run: |
curl https://uploader.codecov.io/latest/linux/codecov \
--silent --remote-name
chmod +x codecov
./codecov --token "${{ secrets.CODECOV_TOKEN }}"
if: github.ref == 'refs/heads/main'
clean:
needs: reports
runs-on: ubuntu-latest
steps:
- name: Clean
uses: geekyeggo/delete-artifact@v1
with:
name: repository