Weeknotes: 2nd March 2020
This week I wrote controller unit tests
This might not sound like much of an achievement, but it’s been a big gap in our testing coverage.
The limiting factor has been how to mock out services: we want to ensure the email sender is used, but not actually send it.
A few things have made this easier: enabling autowiring, a better understanding of Symfony and its configuration options, and a real need for these tests.
As far as I’m aware, there’s now nothing we can’t test. This is great news for our test confidence, but also our coverage measurement: if we can cover everything in unit tests, we can measure it easily. Up until now we’ve been limited to end-to-end testing, which is hard to measure.
Summary
- Finished moving my portion of emails to GOV.UK Notify
- Wrote unit tests for some related controllers
- Updated design of administration panel
- This has been a long time coming
- Created command for the document synchroniser
- This is fully tested and can run in the background. It’s really building on our good work in the past few months
- Wrote a set of stories for changing our data structure to support multiple deputy types per client
- Picked up LSGNT work for the first time in a while, aiming to get it back on track
- And a whole lot of house stuff which got in the way of everything