heroku / php-getting-started

Getting Started with PHP on Heroku.
https://devcenter.heroku.com/articles/getting-started-with-php
194 stars 2 forks source link

Add example tests, that can be run by Heroku CI #53

Open edmorley opened 3 years ago

edmorley commented 3 years ago

I tried enabling Heroku CI on a Heroku pipeline linked to this repository, however the CI run failed with:

-----> Running PHP buildpack tests...
realpath: vendor/bin: No such file or directory
Trying to auto-detect test framework; first match will be found. You may use composer script 'test', or app.json, to specify what to run.
No tests found. Please use composer script 'test', or app.json, to specify what to run.
-----> PHP buildpack tests failed with exit status 1

(see https://dashboard.heroku.com/pipelines/fd8213bf-4356-40a1-aab8-c7042a64713e/tests/1)

I think it would be useful to add some example tests to this repo, since:

  1. It gives people something on which they can base their own tests
  2. They can help verify the correctness of this example project, so we're not just relying on Review Apps.
edmorley commented 3 years ago

cc @dzuelke

dzuelke commented 5 months ago

FWIW, the error message is not the cause for no tests being found (it's due to the cwd being the buildpack dir when the .profile.d scripts get executed).