Run tests in hook