Skip to content
This repository has been archived by the owner on Dec 11, 2021. It is now read-only.

Commit

Permalink
Merge pull request #16 from shochdoerfer/feature/gh_actions
Browse files Browse the repository at this point in the history
Add GitHub Action configuration
  • Loading branch information
shochdoerfer committed Jan 23, 2021
2 parents f979f7e + 28aae6a commit ae210e9
Show file tree
Hide file tree
Showing 4 changed files with 64 additions and 23 deletions.
3 changes: 3 additions & 0 deletions .coveralls.yml
@@ -0,0 +1,3 @@
coverage_clover: clover.xml
json_path: coveralls-upload.json

61 changes: 61 additions & 0 deletions .github/workflows/ci.yml
@@ -0,0 +1,61 @@
name: ci
on: [push, pull_request]

jobs:
run:
runs-on: ${{ matrix.operating-system }}
strategy:
matrix:
operating-system: ['ubuntu-latest']
php-versions: ['7.4']
coveralls: [false]
include:
- operating-system: 'ubuntu-latest'
php-versions: '7.4'
coveralls: true
steps:
- name: Checkout repo
uses: actions/checkout@v2

- name: Configure PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php-versions }}
tools: composer:v1
coverage: xdebug

- name: Install Composer dependencies
run: composer install

- name: Linting code
run: ./vendor/bin/phing lint

- name: Codesniffer
run: ./vendor/bin/phing sniff

- name: Static code analysis
run: ./vendor/bin/phing analyse

- name: Magerun
if: matrix.coveralls == false
run: |
wget https://files.magerun.net/n98-magerun2-latest.phar
mkdir -p ~/.n98-magerun2/modules
ln -s $(pwd) ~/.n98-magerun2/modules/magerun2-password-normalizer
php n98-magerun2-latest.phar help dev:customer:normalize-passwords
- name: Unittests
if: matrix.coveralls == false
run: ./vendor/bin/phing unit

- name: Unittests with coverage
if: matrix.coveralls == true
run: ./vendor/bin/phing unit-with-coverage

- name: Coveralls report
if: matrix.coveralls == true
env:
COVERALLS_REPO_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
composer require php-coveralls/php-coveralls
./vendor/bin/php-coveralls --coverage_clover=clover.xml -v
21 changes: 0 additions & 21 deletions .travis.yml

This file was deleted.

2 changes: 0 additions & 2 deletions auth.json.enc

This file was deleted.

0 comments on commit ae210e9

Please sign in to comment.