class ActionMailer::Preview

def preview_name

Returns the underscored name of the mailer preview without the suffix
def preview_name
  name.sub(/Preview$/, '').underscore
end