Skip to content

Commit

Permalink
Workflow update
Browse files Browse the repository at this point in the history
  • Loading branch information
herpaderpaldent committed Sep 28, 2024
1 parent 86dd59e commit 1e670ac
Show file tree
Hide file tree
Showing 7 changed files with 93 additions and 67 deletions.
31 changes: 31 additions & 0 deletions .github/workflows/formats.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: Formats

on:
push:
paths:
- '**.php'

jobs:
ci:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v3

- name: Setup PHP
uses: shivammathur/setup-php@v2 #https://github.com/shivammathur/setup-php
with:
php-version: '8.3'

- name: Install Composer dependencies
run: composer update --no-ansi --no-interaction --no-scripts --no-progress --prefer-dist

- name: Coding Style Checks
run: composer test:lint

- name: Type Checks
run: composer test:types

- name: Type Coverage Checks
run: composer test:type-coverage
23 changes: 0 additions & 23 deletions .github/workflows/php-cs-fixer.yml

This file was deleted.

35 changes: 0 additions & 35 deletions .github/workflows/run-tests.yml

This file was deleted.

29 changes: 29 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Tests

on:
push:
branches: [ 2.x, 3.x ]
pull_request:
branches: [ 2.x, 3.x ]

jobs:
ci:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- name: Setup PHP, with composer and extensions
uses: shivammathur/setup-php@v2 #https://github.com/shivammathur/setup-php
with:
php-version: '8.3'
coverage: xdebug #optional
- name: Install Dependencies
run: composer install --no-ansi --no-interaction --no-scripts --no-progress --prefer-dist
- name: Test & publish code coverage
uses: paambaati/[email protected]
env:
CC_TEST_REPORTER_ID: 55a033428e7f980c68f3fe5e8f335098915f318d06843848ad2070fef53e331e
with:
coverageCommand: vendor/bin/pest --coverage --ci --min=100
debug: false
11 changes: 7 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
# Esi-Client

[![Latest Version on Packagist](https://img.shields.io/packagist/v/seatplus/esi-client.svg?style=flat-square)](https://packagist.org/packages/seatplus/esi-client)
[![run-tests](https://github.com/seatplus/esi-client/actions/workflows/run-tests.yml/badge.svg?branch=2.x)](https://github.com/seatplus/esi-client/actions/workflows/run-tests.yml)
[![Check & fix styling](https://github.com/seatplus/esi-client/actions/workflows/php-cs-fixer.yml/badge.svg?branch=2.x)](https://github.com/seatplus/esi-client/actions/workflows/php-cs-fixer.yml)
[![Total Downloads](https://img.shields.io/packagist/dt/seatplus/esi-client.svg?style=flat-square)](https://packagist.org/packages/seatplus/esi-client)
[![Latest Stable Version](https://poser.pugx.org/seatplus/esi-client/v/stable)](https://packagist.org/packages/seatplus/esi-client)
[![Tests](https://github.com/seatplus/esi-client/actions/workflows/tests.yml/badge.svg)](https://github.com/seatplus/esi-client/actions/workflows/tests.yml)
[![Formats](https://github.com/seatplus/esi-client/actions/workflows/formats.yml/badge.svg)](https://github.com/seatplus/esi-client/actions/workflows/formats.yml)
[![Maintainability](https://api.codeclimate.com/v1/badges/9c06342438c0fb4a4cdc/maintainability)](https://codeclimate.com/github/seatplus/esi-client/maintainability)
[![Test Coverage](https://api.codeclimate.com/v1/badges/9c06342438c0fb4a4cdc/test_coverage)](https://codeclimate.com/github/seatplus/esi-client/test_coverage)
[![Total Downloads](https://poser.pugx.org/seatplus/esi-client/downloads)](https://packagist.org/packages/seatplus/esi-client)
[![License](https://poser.pugx.org/seatplus/esi-client/license)](https://packagist.org/packages/seatplus/esi-client)

A standalone ESI (Eve Swagger Interface) Client Library using kevinrob/guzzle-cache-middleware.

Expand Down
23 changes: 18 additions & 5 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,11 +33,14 @@
"require-dev": {
"ext-openssl": "*",
"fzaninotto/faker": "^1.5",
"illuminate/cache": "^8.60",
"illuminate/cache": "^11.23",
"laravel/pint": "^1.17",
"mikey179/vfsstream": "^1",
"mockery/mockery": "^1.4",
"nunomaduro/collision": "^7.0",
"pestphp/pest": "^2.0",
"nunomaduro/collision": "^8.0",
"pestphp/pest": "^3.0",
"pestphp/pest-plugin-type-coverage": "^3.0",
"phpstan/phpstan": "^1.12",
"rector/rector": "^1.2"
},
"autoload": {
Expand All @@ -52,8 +55,18 @@
}
},
"scripts": {
"test": "./vendor/bin/pest",
"test-coverage": "XDEBUG_MODE=coverage ./vendor/bin/pest --coverage"
"lint": "vendor/bin/pint",
"test:lint": "vendor/bin/pint --test",
"test:types": "vendor/bin/phpstan --ansi",
"test:type-coverage": "vendor/bin/pest --type-coverage --min=100",
"test:unit": "vendor/bin/pest --colors=always",
"test:unit-coverage": "XDEBUG_MODE=coverage vendor/bin/pest --coverage --colors=always",
"test": [
"@test:lint",
"@test:types",
"@test:type-coverage",
"@test:unit"
]
},
"config": {
"sort-packages": true,
Expand Down
8 changes: 8 additions & 0 deletions phpstan.neon.dist
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
parameters:
editorUrl: 'phpstorm://open?file=%%file%%&line=%%line%%'
level: 4
paths:
- src
tmpDir: build/phpstan


0 comments on commit 1e670ac

Please sign in to comment.