typical-data
typical-data copied to clipboard
Re-assess ordering of global afterBuild hooks
Right now global afterBuild hooks are ran after trait afterBuild hooks. When combined with extended factories, this may lead to unintuitive execution order of hooks.
Running global hooks after results in parent hooks being mixed in with child hooks:
- child trait hooks
- parent global hook
- child global hook
Running global hooks before results in a more intuitive ordering that follows the inheritance hierarchy:
- parent global hook
- child global hook
- child trait hooks