https://github.com/davidjeddy/silex-test
A test application leveraging the Silex micro framework, Codecetion functional testing, and docker ENV control.
https://github.com/davidjeddy/silex-test
Last synced: 3 months ago
JSON representation
A test application leveraging the Silex micro framework, Codecetion functional testing, and docker ENV control.
- Host: GitHub
- URL: https://github.com/davidjeddy/silex-test
- Owner: davidjeddy
- Created: 2016-12-24T15:33:51.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2023-04-17T19:08:39.000Z (about 2 years ago)
- Last Synced: 2025-01-16T11:33:01.265Z (5 months ago)
- Language: PHP
- Homepage: https://github.com/davidjeddy/silex-test
- Size: 134 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
Silex Test
===
A test application leveraging the Silex micro framework, codeception functional automated testing,
and docker containerization.Contrib
===
David J EddyLic
===
https://opensource.org/licenses/MITRequirements
===
Basic linux terminal skills[Terminal](https://www.digitalocean.com/community/tutorials/an-introduction-to-the-linux-terminal)
[Docker](https://www.docker.com/)
Installation
===
First copy .env.dist as .env and edit values as needed (defaults are provided)cp ./docker/code/.env.dist ./docker/code/.env
Next setup the container environment
docker-compose up --build
Once the env is setup open a new terminal window and install dependencies
docker-compose run vendor composer install --profile -o -vvv
Finally, check the IP of the DB container(s). Edit the .env to matchdocker inspect silextest_db_1 | grep IPAddress
docker inspect silextest_db_test_1 | grep IPAddressUsage
===
Once the container system is built the application will be accessible via HTTP requests athttp://localhost:8080/
Testing
===
Bring the environment up viadocker-compose up --build
Build the Codeception test suite (needed once per container build or if conguration is changed)
docker-compose run code codecept build -c ./tests
Build and run Codeception testing suites in one step
docker-compose run code codecept run -c ./testsObserve output
If you make changes to the codeception configuration rebuilding the generated classes is required
docker-compose run code codecept build -c ./tests