aboutsummaryrefslogtreecommitdiffstats
path: root/actionmailbox/lib
diff options
context:
space:
mode:
authorcolorbox <colorbox222@gmail.com>2019-01-16 00:55:42 +0900
committercolorbox <colorbox222@gmail.com>2019-01-17 01:10:21 +0900
commit620ba4c12a6a075607c260fe30c95e51b51b878f (patch)
treeb61c16bc77c5c685389f7f79099f73823fb57a53 /actionmailbox/lib
parentd67863af390b45ed8dde551071a29b3d347bb8be (diff)
downloadrails-620ba4c12a6a075607c260fe30c95e51b51b878f.tar.gz
rails-620ba4c12a6a075607c260fe30c95e51b51b878f.tar.bz2
rails-620ba4c12a6a075607c260fe30c95e51b51b878f.zip
Fix document formatting on ActionMailbox [ci skip]
Use `+` instead of backquote.
Diffstat (limited to 'actionmailbox/lib')
-rw-r--r--actionmailbox/lib/action_mailbox/base.rb24
-rw-r--r--actionmailbox/lib/action_mailbox/router/route.rb2
-rw-r--r--actionmailbox/lib/action_mailbox/routing.rb2
-rw-r--r--actionmailbox/lib/action_mailbox/test_helper.rb12
4 files changed, 20 insertions, 20 deletions
diff --git a/actionmailbox/lib/action_mailbox/base.rb b/actionmailbox/lib/action_mailbox/base.rb
index 4ac594b9f8..ff8587acd1 100644
--- a/actionmailbox/lib/action_mailbox/base.rb
+++ b/actionmailbox/lib/action_mailbox/base.rb
@@ -7,7 +7,7 @@ require "action_mailbox/routing"
module ActionMailbox
# The base class for all application mailboxes. Not intended to be inherited from directly. Inherit from
- # `ApplicationMailbox` instead, as that's where the app-specific routing is configured. This routing
+ # +ApplicationMailbox+ instead, as that's where the app-specific routing is configured. This routing
# is specified in the following ways:
#
# class ApplicationMailbox < ActionMailbox::Base
@@ -27,15 +27,15 @@ module ActionMailbox
# routing :all => :backstop
# end
#
- # Application mailboxes need to overwrite the `#process` method, which is invoked by the framework after
- # callbacks have been run. The callbacks available are: `before_processing`, `after_processing`, and
- # `around_processing`. The primary use case is ensure certain preconditions to processing are fulfilled
- # using `before_processing` callbacks.
+ # Application mailboxes need to overwrite the +#process+ method, which is invoked by the framework after
+ # callbacks have been run. The callbacks available are: +before_processing+, +after_processing+, and
+ # +around_processing+. The primary use case is ensure certain preconditions to processing are fulfilled
+ # using +before_processing+ callbacks.
#
- # If a precondition fails to be met, you can halt the processing using the `#bounced!` method,
+ # If a precondition fails to be met, you can halt the processing using the +#bounced!+ method,
# which will silently prevent any further processing, but not actually send out any bounce notice. You
# can also pair this behavior with the invocation of an Action Mailer class responsible for sending out
- # an actual bounce email. This is done using the `#bounce_with` method, which takes the mail object returned
+ # an actual bounce email. This is done using the +#bounce_with+ method, which takes the mail object returned
# by an Action Mailer method, like so:
#
# class ForwardsMailbox < ApplicationMailbox
@@ -50,12 +50,12 @@ module ActionMailbox
# end
#
# During the processing of the inbound email, the status will be tracked. Before processing begins,
- # the email will normally have the `pending` status. Once processing begins, just before callbacks
- # and the `#process` method is called, the status is changed to `processing`. If processing is allowed to
- # complete, the status is changed to `delivered`. If a bounce is triggered, then `bounced`. If an unhandled
- # exception is bubbled up, then `failed`.
+ # the email will normally have the +pending+ status. Once processing begins, just before callbacks
+ # and the +#process+ method is called, the status is changed to +processing+. If processing is allowed to
+ # complete, the status is changed to +delivered+. If a bounce is triggered, then +bounced+. If an unhandled
+ # exception is bubbled up, then +failed+.
#
- # Exceptions can be handled at the class level using the familiar `Rescuable` approach:
+ # Exceptions can be handled at the class level using the familiar +Rescuable+ approach:
#
# class ForwardsMailbox < ApplicationMailbox
# rescue_from(ApplicationSpecificVerificationError) { bounced! }
diff --git a/actionmailbox/lib/action_mailbox/router/route.rb b/actionmailbox/lib/action_mailbox/router/route.rb
index b681eb7ea8..7e98e83382 100644
--- a/actionmailbox/lib/action_mailbox/router/route.rb
+++ b/actionmailbox/lib/action_mailbox/router/route.rb
@@ -2,7 +2,7 @@
module ActionMailbox
# Encapsulates a route, which can then be matched against an inbound_email and provide a lookup of the matching
- # mailbox class. See examples for the different route addresses and how to use them in the `ActionMailbox::Base`
+ # mailbox class. See examples for the different route addresses and how to use them in the +ActionMailbox::Base+
# documentation.
class Router::Route
attr_reader :address, :mailbox_name
diff --git a/actionmailbox/lib/action_mailbox/routing.rb b/actionmailbox/lib/action_mailbox/routing.rb
index 1ea96c8a9d..58462a44c6 100644
--- a/actionmailbox/lib/action_mailbox/routing.rb
+++ b/actionmailbox/lib/action_mailbox/routing.rb
@@ -1,7 +1,7 @@
# frozen_string_literal: true
module ActionMailbox
- # See `ActionMailbox::Base` for how to specify routing.
+ # See +ActionMailbox::Base+ for how to specify routing.
module Routing
extend ActiveSupport::Concern
diff --git a/actionmailbox/lib/action_mailbox/test_helper.rb b/actionmailbox/lib/action_mailbox/test_helper.rb
index 02c52fb779..0ec9152844 100644
--- a/actionmailbox/lib/action_mailbox/test_helper.rb
+++ b/actionmailbox/lib/action_mailbox/test_helper.rb
@@ -4,38 +4,38 @@ require "mail"
module ActionMailbox
module TestHelper
- # Create an `InboundEmail` record using an eml fixture in the format of message/rfc822
+ # Create an +InboundEmail+ record using an eml fixture in the format of message/rfc822
# referenced with +fixture_name+ located in +test/fixtures/files/fixture_name+.
def create_inbound_email_from_fixture(fixture_name, status: :processing)
create_inbound_email_from_source file_fixture(fixture_name).read, status: status
end
- # Create an `InboundEmail` by specifying it using `Mail.new` options. Example:
+ # Create an +InboundEmail+ by specifying it using +Mail.new+ options. Example:
#
# create_inbound_email_from_mail(from: "david@loudthinking.com", subject: "Hello!")
def create_inbound_email_from_mail(status: :processing, **mail_options)
create_inbound_email_from_source Mail.new(mail_options).to_s, status: status
end
- # Create an `InboundEmail` using the raw rfc822 `source` as text.
+ # Create an +InboundEmail+ using the raw rfc822 +source+ as text.
def create_inbound_email_from_source(source, status: :processing)
ActionMailbox::InboundEmail.create_and_extract_message_id! source, status: status
end
- # Create an `InboundEmail` from fixture using the same arguments as `create_inbound_email_from_fixture`
+ # Create an +InboundEmail+ from fixture using the same arguments as +create_inbound_email_from_fixture+
# and immediately route it to processing.
def receive_inbound_email_from_fixture(*args)
create_inbound_email_from_fixture(*args).tap(&:route)
end
- # Create an `InboundEmail` from fixture using the same arguments as `create_inbound_email_from_mail`
+ # Create an +InboundEmail+ from fixture using the same arguments as +create_inbound_email_from_mail+
# and immediately route it to processing.
def receive_inbound_email_from_mail(**kwargs)
create_inbound_email_from_mail(**kwargs).tap(&:route)
end
- # Create an `InboundEmail` from fixture using the same arguments as `create_inbound_email_from_source`
+ # Create an +InboundEmail+ from fixture using the same arguments as +create_inbound_email_from_source+
# and immediately route it to processing.
def receive_inbound_email_from_source(**kwargs)
create_inbound_email_from_source(**kwargs).tap(&:route)