Extracting assertions to helper methods