tests for before after