-
Notifications
You must be signed in to change notification settings - Fork 27
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
66c7adc
commit 7418efb
Showing
5 changed files
with
86 additions
and
0 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 @@ | ||
/e2e export-ignore |
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,45 @@ | ||
# https://help.github.com/en/categories/automating-your-workflow-with-github-actions | ||
|
||
name: "Integration tests" | ||
|
||
on: | ||
pull_request: | ||
push: | ||
branches: | ||
- "master" | ||
|
||
jobs: | ||
test: | ||
name: "Integration test" | ||
runs-on: "ubuntu-latest" | ||
|
||
strategy: | ||
matrix: | ||
php-version: | ||
- "7.4" | ||
- "8.0" | ||
|
||
steps: | ||
- name: "Checkout" | ||
uses: "actions/checkout@v2" | ||
|
||
- name: "Install PHP" | ||
uses: "shivammathur/setup-php@v2" | ||
with: | ||
coverage: "none" | ||
php-version: "${{ matrix.php-version }}" | ||
|
||
- name: "Install dependencies" | ||
working-directory: "e2e" | ||
run: "composer install --no-interaction --no-progress --no-suggest" | ||
|
||
- name: "Test" | ||
working-directory: "e2e" | ||
run: "vendor/bin/phpstan analyse -l 8 FooTest.php" | ||
|
||
- name: "Rename directory" | ||
run: "mv e2e e3e" | ||
|
||
- name: "Test relative paths - after renaming" | ||
working-directory: "e3e" | ||
run: "vendor/bin/phpstan analyse -l 8 FooTest.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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
/composer.lock | ||
/vendor |
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,21 @@ | ||
<?php | ||
|
||
namespace App; | ||
|
||
use PHPUnit\Framework\TestCase; | ||
|
||
class FooTest extends TestCase | ||
{ | ||
|
||
public function testFoo(?\stdClass $std): void | ||
{ | ||
$this->assertNotNull($std); | ||
$this->requireStd($std); | ||
} | ||
|
||
private function requireStd(\stdClass $std): void | ||
{ | ||
|
||
} | ||
|
||
} |
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,17 @@ | ||
{ | ||
"require": { | ||
"phpstan/phpstan": "^0.12.62", | ||
"phpstan/extension-installer": "dev-master", | ||
"phpstan/phpstan-phpunit": "^0.12.17", | ||
"phpunit/phpunit": "^9.5" | ||
}, | ||
"repositories": [ | ||
{ | ||
"type": "path", | ||
"url": "..", | ||
"options": { | ||
"symlink": false | ||
} | ||
} | ||
] | ||
} |