Added before() and after() function calls to the root (probably won't cascade to all substates (yet))
Rewrote test for skipping generations for nested function calls.