I purposefully delayed the options and the tests till last. For the tests, they are kinda a nice to have that gives me a bit of practice writing tests in this language, but they are not really a high priority. On Sunday when I was going to do the tests, I ended up helping someone move. Probably healthier for me in the long run. :-D
The code cleanup was kinda fun. I got rid of a module I never used. I also added some functions that made working with the input list struct more manageable. I think the code looks a bit more like how an Elixir programmer would write it now.
With the options, I was procrastinating. Honestly I think it is because I only have a vague sense of what I want there. What I mean is I can clearly see the 2 types of options I previously specified, but no others. I don't want to lock it down to just those two and realize later that I need to add some other options. So for this week, before I implement options, I am going to give it a good look, and bite the bullet.
The first book, while less fun this week was very useful. It walked me through how to authenticate, and add users. I may have misunderstood but it looks like he took me through a more hands on way of doing that, rather than using a module. So on one hand I know more about Phoenix, and how to do another part of my project, but on the other hand I plan to look for an easier possibly more standard way.
The second book was more enjoyable. It gave me a better understanding of OTP's GenServer. In this book he is making a battleship clone, and he is using GenServer for concurrency; one per game. It is neat seeing him tie it all together.
Last week's goals:
- Add options for number of choices per question
- Add options for number of questions per section
Phoenix Book Chapter 5, 6, and maybe 7 Second Phoenix Book Chapter 4 Add Matching Section Set up the Github repo
- Add 5 tests
Reformatted and cleaned up code. Made a quick script to help automate a local task
The github repo is,up. I'll fix the documentation this week. Feel free to check out the code and let me know if I am making any major mistakes.
This week's goals:
- Phoenix Book Chapter 6, & maybe 7 - 1 hour
- Second Phoenix Book Chapter 5 - 1.5 hours
- Implement options... or else. :-( - 2 hours
- Clean up documentation - 30 minutes
- Web app skeleton - 15 minutes
- Add 5 tests - 30 minutes
Everything I am doing this week is fairly self explanatory. I should be able to knock out this list no problem. /me knocks on wood.
Next week's post I'll put up an updated outline. At that point we'll have covered almost 1/4 of the project, and 2 of the original milestones would be reached.