Refactor generate and hook tests - partial checkin.
Fix test_hooks again.
Modify find_hooks to work with work_in() change.