A small, Symfony-based project checking your backend development skills.
- Symfony 6.x, Doctrine, MySQL/Postgresql
- Docker environment
- Unit and functional test
Create a Symfony app with a REST API returning JSON containing stock information.
-
Create docker-compose based development environment (you can use webdeveops/php-nginx-dev image)
-
Create command consuming csv files and importing its data to database
- command should have two arguments: absolute filepath and supplier name
- every supplier might have different file format (take this into account)
- ideally every supplier should have his own processor/transformer
-
Create unit tests for classes responsible for transforming csv file records into entities.
-
On our stock item entity we would like to store information:
- EAN (or null if not present)
- MPN (manufacturer producer number)
- Producer name
- External id
- Price
- Quantity
-
Prepare anonymous API with one endpoint:
a) /get-stocks endpoint
-
with two query attributes:
- mpn
- ean
where at least one must be specified in order to return any results.
-
respectively return results based on filtering by mpn or ean field.
-
result should contain all data available for each stock item
-
-
Create functional test of created api endpoint (using phpunit + symfony WebTestCase), ideally using zenstruck/foundry for fixtures but its not a must.
Inside data directory there are two files from different suppliers with some additional information about how to parse them.
Once completed, submit to any public git repository and provide us with link.