Run 'codecept build' before runninng PHPStan checks

This commit adds a call to the command 'codecept build' before running
PHPStan checks inside the command './do qa:phpstan'. This is needed to
make sure that the PHPStan checks don't fail with the error bellow
because of missing test support files that are autogenerated by
Codeception:

```
Bootstrap file tests/_support/_generated/AcceptanceTesterActions.php does not exist.
```

[MAILPOET-3552]
This commit is contained in:
Rodrigo Primo
2021-09-23 11:10:22 -03:00
committed by Veljko V
parent d9862c97d5
commit 06ddc42657

View File

@@ -474,6 +474,9 @@ class RoboFile extends \Robo\Tasks {
$task = "ANALYSIS_PHP_VERSION={$opts['php-version']} $task";
}
// make sure Codeception support files are present to avoid invalid errors when running PHPStan
$this->_exec('vendor/bin/codecept build');
// PHPStan must be run out of main plugin directory to avoid its autoloading
// from vendor/autoload.php where some dev dependencies cause conflicts.
return $this->collectionBuilder()