forked from rjsandim/GetnetSDK
-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
4e99780
commit d0df535
Showing
4 changed files
with
51 additions
and
5 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
name: Run tests | ||
on: | ||
push: | ||
branches: | ||
- feature/drop-support-php56 | ||
pull_request: | ||
types: | ||
- opened | ||
- reopened | ||
- ready_for_review | ||
workflow_dispatch: | ||
jobs: | ||
run-tests: | ||
if: ${{ !github.event.pull_request.draft }} | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
|
||
- name: Add HTTP basic auth credentials | ||
run: echo '${{ secrets.COMPOSER_AUTH_JSON }}' > $GITHUB_WORKSPACE/auth.json | ||
|
||
- name: Install PHP | ||
uses: shivammathur/setup-php@v2 | ||
with: | ||
php-version: "7.4" | ||
extensions: mbstring | ||
tools: composer:v2, phpunit:9.5 | ||
|
||
#TODO test with env github actios | ||
- name: Add config/env.test.php | ||
run: echo '${{ secrets.ENV_PHP }}' > $GITHUB_WORKSPACE/config/env.test.php | ||
|
||
- name: Install dependencies | ||
run: composer update --no-interaction --no-progress --ignore-platform-reqs | ||
|
||
- name: Static analysis | ||
run: composer phpstan | ||
|
||
- name: PHPUnit tests | ||
run: composer phpunit | ||
|
||
- name: Remove temp files | ||
run: rm -f $GITHUB_WORKSPACE/auth.json, $GITHUB_WORKSPACE/config/env.test.php |
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,8 @@ | ||
parameters: | ||
level: 5 | ||
paths: | ||
- / | ||
excludePaths: | ||
- vendor | ||
- src | ||
- tests | ||
- config | ||
- examples | ||
ignoreErrors: |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,7 +6,7 @@ trait TraitEntity | |
|
||
/** | ||
* | ||
* @return array | ||
* @return mixed | ||
*/ | ||
public function jsonSerialize() | ||
{ | ||
|