Skip to content

Commit 7ed6c4a

Browse files
committed
minor #1226 Install stty required for tests on ubuntu-latest (bocharsky-bw)
This PR was squashed before being merged into the main branch. Discussion ---------- Install stty required for tests on ubuntu-latest In every test job we have skipped tests: ``` Run vendor/bin/simple-phpunit -v PHPUnit 9.5.4 by Sebastian Bergmann and contributors. Runtime: PHP 8.0.5 Configuration: /home/runner/work/demo/demo/phpunit.xml.dist Warning: Your XML configuration validates against a deprecated schema. Suggestion: Migrate your XML configuration using "--migrate-configuration"! Testing SSSS........................................... 47 / 47 (100%) Time: 00:14.918, Memory: 74.50 MB There were 4 skipped tests: 1) App\Tests\Command\AddUserCommandTest::testCreateUserNonInteractive with data set #0 (false) `stty` is required to test this command. /home/runner/work/demo/demo/tests/Command/AddUserCommandTest.php:35 2) App\Tests\Command\AddUserCommandTest::testCreateUserNonInteractive with data set #1 (true) `stty` is required to test this command. /home/runner/work/demo/demo/tests/Command/AddUserCommandTest.php:35 3) App\Tests\Command\AddUserCommandTest::testCreateUserInteractive with data set #0 (false) `stty` is required to test this command. /home/runner/work/demo/demo/tests/Command/AddUserCommandTest.php:35 4) App\Tests\Command\AddUserCommandTest::testCreateUserInteractive with data set #1 (true) `stty` is required to test this command. /home/runner/work/demo/demo/tests/Command/AddUserCommandTest.php:35 OK, but incomplete, skipped, or risky tests! Tests: 47, Assertions: 92, Skipped: 4. Remaining indirect deprecation notices (1) 1x: The "DAMA\DoctrineTestBundle\Doctrine\DBAL\AbstractStaticDriverV2" class implements "Doctrine\DBAL\Driver\ExceptionConverterDriver" that is deprecated. 1x in PHPUnitExtension::executeBeforeFirstTest from DAMA\DoctrineTestBundle\PHPUnit ``` It would be good to run those tests at least on Ubuntu I think Commits ------- 944b320 Install stty required for tests on ubuntu-latest
2 parents 9c06dd5 + 944b320 commit 7ed6c4a

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

tests/Command/AddUserCommandTest.php

+2-5
Original file line numberDiff line numberDiff line change
@@ -28,11 +28,8 @@ class AddUserCommandTest extends KernelTestCase
2828

2929
protected function setUp(): void
3030
{
31-
exec('stty 2>&1', $output, $exitcode);
32-
$isSttySupported = 0 === $exitcode;
33-
34-
if ('Windows' === \PHP_OS_FAMILY || !$isSttySupported) {
35-
$this->markTestSkipped('`stty` is required to test this command.');
31+
if ('Windows' === \PHP_OS_FAMILY) {
32+
$this->markTestSkipped('Windows OS does not support testing this command.');
3633
}
3734
}
3835

0 commit comments

Comments
 (0)