This is a simple example application built in response to a coding challenge to demonstrate my technical ability and work processes
- As an Agile developer, I regularly use KANBAN. I built a board for this project to show how I organize my work
- I broke the work down into 3 stories
- An Environment Build Out
- Counting the words in a single message
- Returning the count of all words received thus far
- This allowed me to take an iterative and evolving approach
- https://trello.com/b/odVC9L3R/coding-challenge
- Install Docker https://www.docker.com/products/docker-desktop
gradlew build
- Set environment variable to desired database password
- windows
set WORD_COUNTER_PASSWORD=
- bash
export WORD_COUNTER_PASSWORD=
- windows
- run the custom script file to start both app and database
- windows
bin\dockerComposeUp.bat
- bash
chmod +x bin/dockerComposeUp.sh && ./bin/dockerComposeUp.sh
- windows
There are a suite of end to end test built with Rest Assured in the serviceTest module
- Run app (see above)
gradlew test -PserviceTest --rerun-tasks
- results appear
serviceTest/build/reports/tests/test/index.html
- They are JUnit based so you can also run the from your favorite IDE
- Using Spring Boot as the base level framework to take advantage of the MVC and ORM it provides
- Using Spring Data Jpa to interface with the database
- Using Docker to easily run the api and database
- Using Spring WebMvcTest to test endpoint mappings, json serialization and deserialization, and request payload Validations
- Using Spring DataJpaTest to test entity mappings and repository calls
- Using Test Containers to run a real postgres docker container for DataJpaTest tests and the Application start test
- All other functionality has been covered by Unit tests
- Using Rest Assured for end-2-end tests