Skip to content

Commit

Permalink
Run tests with both host + docker
Browse files Browse the repository at this point in the history
  • Loading branch information
AydinHassan committed May 25, 2024
1 parent 1dc4d4a commit 75ef338
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
3 changes: 2 additions & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,8 @@ jobs:
- name: Run phpunit tests
run: |
mkdir -p build/logs
vendor/bin/phpunit --coverage-clover ./build/logs/clover.xml
PROCESS_FACTORY=host vendor/bin/phpunit
PROCESS_FACTORY=docker vendor/bin/phpunit --coverage-clover ./build/logs/clover.xml
- name: Run phpcs
run: composer cs

Expand Down
2 changes: 1 addition & 1 deletion phpunit.xml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,6 @@
<exclude>./test/solutions</exclude>
</testsuite>
<php>
<env name="process_factory" value="docker" force="true" />
<env name="PROCESS_FACTORY" value="docker" />
</php>
</phpunit>
2 changes: 1 addition & 1 deletion test/Exercise/ThrowAnExpressionTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ public function testThrowingWrongException(): void
self::assertInstanceOf(Success::class, $output->getResults()[1]);

self::assertMatchesRegularExpression(
'/Fatal error: Uncaught Exception: Access denied!/',
'/Fatal error:\s+Uncaught Exception: Access denied!/',
$output->getResults()[0]->getReason()
);

Expand Down

0 comments on commit 75ef338

Please sign in to comment.