[PATCH 1/2] test: add general Emacs hook counter