I am using the PHP 8 constructor property promotion feature in my Laravel 8 project. It works perfectly, but when you try to test it, the coverage does not consider the constructor as tested.
Packages:
public function __construct( private int $id, private string $name ) { } public function getId(): int { return $this->id; } public function getName(): string { return $this->name; }
Coverage Report:
1.4m articles
1.4m replys
5 comments
57.0k users