I write unit tests only for code which broke during the development phase and of cause after shipping. But I write test scenarios and test plans for integration tests before coding. Because the chosen technology stack or the exchanged technology stack must pass the integration tests.
I do this because I'm confident enough trusting my language/platform/framework/library/skills. It makes no sense to me to write tests for stupid/simple/pure functions like logging or doing additions and the likes.