nitunit: fix `before-all` and `after-all` detection