aboutsummaryrefslogtreecommitdiffstats
path: root/test/unit/router_test.rb
diff options
context:
space:
mode:
Diffstat (limited to 'test/unit/router_test.rb')
-rw-r--r--test/unit/router_test.rb9
1 files changed, 9 insertions, 0 deletions
diff --git a/test/unit/router_test.rb b/test/unit/router_test.rb
index 67a5f24c52..cc87ae6c0e 100644
--- a/test/unit/router_test.rb
+++ b/test/unit/router_test.rb
@@ -49,6 +49,15 @@ module ActionMailbox
assert_equal inbound_email.mail, $processed_mail
end
+ test "single string routing case-insensitively" do
+ @router.add_routes("first@example.com" => :first)
+
+ inbound_email = create_inbound_email_from_mail(to: "FIRST@example.com", subject: "This is a reply")
+ @router.route inbound_email
+ assert_equal "FirstMailbox", $processed_by
+ assert_equal inbound_email.mail, $processed_mail
+ end
+
test "multiple string routes" do
@router.add_routes("first@example.com" => :first, "second@example.com" => :second)