Cover commit counting mechanism with tests

Fix #79