Ruby on Rails | Screencasts | Download | Documentation | Weblog | Community | Source

Ticket #1910 (closed defect: fixed)

Opened 3 years ago

Last modified 3 years ago

[PATCH] assert_redirected_to does not properly check URLs passed as strings (including named routes)

Reported by: htonl Assigned to: David
Priority: high Milestone:
Component: ActionPack Version: 0.13.1
Severity: critical Keywords:
Cc:

Description

Doing the following will not behave correctly:

assert_redirected_to 'http://foo.com/bad_path'
# or
assert_redirected_to wrong_route_url

Only the host part will be compared, the code to test the path parts will not be executed unless one of the hosts parts is nil. Patch adds a test case and fix.

Attachments

ap-assert-redirected-to.diff (2.2 kB) - added by htonl on 08/04/05 20:52:41.
Patch for #1910

Change History

08/04/05 20:52:41 changed by htonl

  • attachment ap-assert-redirected-to.diff added.

Patch for #1910

08/06/05 08:37:47 changed by minam

  • status changed from new to closed.
  • resolution set to fixed.