Re:Ask HN: Which are the best resources to learn software ar...
by insulanian on Sunday February 02, 2020 @03:19AM
(#22215846)
How do you write unit tests your service layer then?
Unit testing is much more important in dynamic languages, because there's no compiler to protect you from basic mistakes.
When working with a language like Go, where I have a DB access layer where I'm running raw SQL queries, I agree with this.
When working with Rails, though, I typically just make ActiveRecord calls in my service layer; it's simpler.