superlint/test/linters/php_phpcs/php_good_2.php
Marco Ferrari e6cf8d3845
Move tests to the test directory (#4985)
* Move tests to the test directory

* Fix linting errors

* Add states back

* Add xml back
2023-12-15 08:50:35 +00:00

25 lines
382 B
PHP

<?php
/**
* @return array<string>
*/
function helloName(string $name): array
{
return ["hello", $name];
}
function helloSuperLinter(): void
{
$hello = helloName("Super-Linter");
echo implode(" ", $hello) . PHP_EOL;
}
function helloOrWorld(): void
{
$random = rand(0, 10);
if ($random >= 5) {
echo "Hello";
} else {
echo "World";
}
}