Added Testing helper classes strict types

pull/532/head
fadrian06 1 year ago
parent 7015e5d3ba
commit 0eac13f4fa

@ -1,5 +1,7 @@
<?php <?php
declare(strict_types=1);
class Factory class Factory
{ {
// Cannot be instantiated // Cannot be instantiated

@ -1,13 +1,15 @@
<?php <?php
declare(strict_types=1);
class Hello class Hello
{ {
public function sayHi() public function sayHi(): string
{ {
return 'hello'; return 'hello';
} }
public static function sayBye() public static function sayBye(): string
{ {
return 'goodbye'; return 'goodbye';
} }

@ -1,5 +1,7 @@
<?php <?php
declare(strict_types=1);
class TesterClass class TesterClass
{ {
public $param1; public $param1;

@ -1,10 +1,12 @@
<?php <?php
declare(strict_types=1);
class User class User
{ {
public $name; public string $name;
public function __construct($name = '') public function __construct(string $name = '')
{ {
$this->name = $name; $this->name = $name;
} }

Loading…
Cancel
Save