[openstreetmap/openstreetmap-website] Add Docker Compose Support for Development Environment (#2409)

Michal Migurski notifications at github.com
Thu Dec 17 16:21:32 UTC 2020


> So how do the test database(s) get created? 

The DB is created by specifying a config ENV var for the [postgres Docker image](https://hub.docker.com/_/postgres); that happens at this line of [docker-compose.yml](https://github.com/jalessio/openstreetmap-website/blob/801d5b6261be6da4c1d47fc9679a8c74ec699370/docker-compose.yml#L23).

> And having the tests pass is a key part of the development environment.

lol 👍 

This might be putting too much pressure on the Docker setup. The [test config we’ve defined here](https://github.com/jalessio/openstreetmap-website/blob/801d5b6261be6da4c1d47fc9679a8c74ec699370/.travis.yml#L3-L41) continues to run the application tests outside of Docker [just as in the default branch, pre-3002](https://github.com/openstreetmap/openstreetmap-website/blob/1b4a06adef58262a3e9eba47049a6ca212d88be4/.travis.yml). The [Docker-specific test](https://github.com/jalessio/openstreetmap-website/blob/801d5b6261be6da4c1d47fc9679a8c74ec699370/.travis.yml#L42-L59) just checks that the dev environment results in a functional Rails site so that casual contributors can test their changes. As an occasional contributor, I never run the test suite locally and rely on the CI to do it for me. 

I’ll read up on Geckodriver and PhantomJS.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/pull/2409#issuecomment-747545760
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20201217/e8d2372a/attachment.htm>


More information about the rails-dev mailing list