extend tests
slight refactor, and add before/after