These are the build steps I tend to use for test environment when running build scripts of symfony applications I work on.


Steps


Steps are run in given order and with --env=test flag where it applies.


  1. Clear cache and logs folders

  2. Grant permissions to cache and logs folders

  3. Cache warm

  4. Composer self-update

  5. Composer install

  6. Generate entity setters and getters: doctrine:generate:entities

  7. Create database: doctrine:database:create

  8. Validate database: doctrine:schema:validate

  9. Load data fixtures: doctrine:fixtures:load

  10. Check codding standards with PHPCSFIXER

  11. Detect code mess with PHPMD

  12. Check code duplicates with PHPCPD

  13. Run PHPSPEC test

  14. Run BEHAT test

  15. Create documentation with PHPDOCUMENTOR

  16. Run Symfony security check

Note


If you use Phing, you can run all these steps in your local computer.