Probably you know if I run git log within a git repository, I could read a story of life. And I like this kind of stories because they show you everything about the code I may work with. From the other side, if I run git commit, I will add a new chapter to the story. And someone else will read it. That’s why I need to make sure the commit message, I wrote, will be a useful chapter.

In the previous post, we looked at the ways how to close connection safely. But there still is one more task: how to connect to a source on in the case when the interaction will happen? This task appears because a lot of connections are designed in a way that you have to connect to a source before start using the connection. Let’s see how lazy connection can be implemented.

Writing automated tests, we often have to interact with a database or a linux host. Different libraries allow us connecting to desired targets and interacting with them. Usually, a connection has to be created first, then it’s possible to implement any desired interactions, and the connection has to be destroyed in the end of the interactions. Looks like everything is very logical and simple. But why there are so many errors in the implementations?

Enabling Touch ID for sudo

Add auth sufficient to the top of /etc/pam.d/sudo and enjoy!

Often people comment the code to debug a test. For instance, there is a python’s module with 5 tests. And just one of them has to be used for debugging. So, usually, all other tests will be commented during the debugging or test development. How to improve this experience?