Fix hooks with rspec integration