This solution contains a Symphony4 project (using PHP7.2, I love its new typing system :-) ).
In order to run this project, please follow the following steps:
- Make sure you have a proper LAMP stack running on your system manily PHP7 , MySQL. For the server you can use the framework builtin server by using "serve" command
- Install Symphony cli on your system
- Create a database for the project
- Set up the proper db connection string in .env file, ex: DATABASE_URL=mysql://root:root@127.0.0.1:3306/poker_hands
- Generate and run the migration (commands below), in the repo you will also find a db.sql file which can be imported directly
- php bin/console make:migration
- php bin/console run:migration
I really enjoyed solving this test , it was quite challenging . This is also my first try using Symphony overall I found it familiar to technologies I used before in the past mainly it resembles NestJS in regards to DTOs , Repositories , and Services (dep Injection) , while also being very similar to Laravel in terms of the general structure and code guidelines (PSR, MVC).
The Poker Solution was inspired by : Mathcs Java Poker