bind model context to lifecycle callbacks

- resolves #230
added quick unit test for lifecycle callback context
Merge pull request #611 from tjwebb/issues/230/lifecycle-context

Issues/230/lifecycle context