lambdaclass / erlings

Small exercises to get you used to reading and writing Erlang code
MIT License
177 stars 27 forks source link

Refactoring of priority exercise #1

Closed herdigiorgi closed 6 years ago

herdigiorgi commented 6 years ago
facundoolano commented 6 years ago

Here's an idea to improve this exercise: instead of printing, the processing could consist in pushing a value (for example the priority atom vip/normal) to a list in the state of the loop process. Then you could add a call to the server that returns the current state.

Using this you could have a proper unit test instead of just checking the console output.