Move CI to GitHub actions (#93)
This commit is contained in:
parent
d566d2b344
commit
b66801d7d2
35
.github/workflows/ci.yml
vendored
Normal file
35
.github/workflows/ci.yml
vendored
Normal file
@ -0,0 +1,35 @@
|
||||
name: ci
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- '**'
|
||||
tags-ignore:
|
||||
- '*.*'
|
||||
pull_request:
|
||||
|
||||
jobs:
|
||||
test:
|
||||
runs-on: ubuntu-latest
|
||||
strategy:
|
||||
matrix:
|
||||
php-version: ['7.0', '7.1', '7.2', '7.3', '7.4']
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- name: Setup PHP ${{ matrix.php-version }}
|
||||
uses: shivammathur/setup-php@v2
|
||||
with:
|
||||
php-version: ${{ matrix.php-version }}
|
||||
ini-values: pcov.directory=lib
|
||||
coverage: pcov
|
||||
- name: Composer cache
|
||||
uses: actions/cache@v2
|
||||
with:
|
||||
path: ${{ env.HOME }}/.composer/cache
|
||||
key: ${{ runner.os }}-php-${{ hashFiles('**/composer.lock') }}
|
||||
- name: Install dependencies
|
||||
run: composer install -o
|
||||
- name: Run tests
|
||||
run: php ./vendor/phpunit/phpunit/phpunit -c phpunit.xml.dist
|
||||
- name: Coverage
|
||||
run: bash <(curl -s https://codecov.io/bash)
|
20
.travis.yml
20
.travis.yml
@ -1,20 +0,0 @@
|
||||
language: php
|
||||
|
||||
cache:
|
||||
directories:
|
||||
- $HOME/.composer/cache
|
||||
|
||||
php:
|
||||
- '7.0'
|
||||
- '7.1'
|
||||
- '7.2'
|
||||
- '7.3'
|
||||
|
||||
before_script:
|
||||
- flags="-o"
|
||||
- composer install $flags
|
||||
|
||||
script: php ./vendor/phpunit/phpunit/phpunit -c phpunit.xml.dist
|
||||
|
||||
after_success:
|
||||
- bash <(curl -s https://codecov.io/bash)
|
@ -1,7 +1,8 @@
|
||||
[![Build Status](https://img.shields.io/travis/retailcrm/api-client-php/master.svg?style=flat-square)](https://travis-ci.org/retailcrm/api-client-php)
|
||||
[![Covarage](https://img.shields.io/codecov/c/gh/retailcrm/api-client-php/master.svg?style=flat-square)](https://codecov.io/gh/retailcrm/api-client-php)
|
||||
[![Latest stable](https://img.shields.io/packagist/v/retailcrm/api-client-php.svg?style=flat-square)](https://packagist.org/packages/retailcrm/api-client-php)
|
||||
[![PHP from Packagist](https://img.shields.io/packagist/php-v/retailcrm/api-client-php.svg?style=flat-square)](https://packagist.org/packages/retailcrm/api-client-php)
|
||||
[![Build Status](https://github.com/retailcrm/api-client-php/workflows/ci/badge.svg)](https://github.com/retailcrm/api-client-php/actions)
|
||||
[![Covarage](https://img.shields.io/codecov/c/gh/retailcrm/api-client-php/master.svg?logo=codecov)](https://codecov.io/gh/retailcrm/api-client-php)
|
||||
[![GitHub release](https://img.shields.io/github/release/retailcrm/api-client-php.svg?logo=github)](https://github.com/retailcrm/api-client-php/releases)
|
||||
[![Latest stable](https://img.shields.io/packagist/v/retailcrm/api-client-php.svg)](https://packagist.org/packages/retailcrm/api-client-php)
|
||||
[![PHP from Packagist](https://img.shields.io/packagist/php-v/retailcrm/api-client-php.svg?logo=php)](https://packagist.org/packages/retailcrm/api-client-php)
|
||||
|
||||
|
||||
# retailCRM API PHP client
|
||||
|
Loading…
Reference in New Issue
Block a user