refactor tests to place common code in utilities.rb