# When does in a redirection appear the object memory address?

**URL:** <https://www.ruby-forum.com/t/when-does-in-a-redirection-appear-the-object-memory-address/180153>\
**Category:** Rails\
**Created:** [December 13, 2009, 2:21pm UTC](https://www.ruby-forum.com/t/when-does-in-a-redirection-appear-the-object-memory-address/180153 "2009-12-13T14:21:48Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![kinunt](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/k/7c8e57/32.png) [@kinunt](https://www.ruby-forum.com/u/kinunt)\
**Post date:** [December 13, 2009, 2:21pm UTC](https://www.ruby-forum.com/t/when-does-in-a-redirection-appear-the-object-memory-address/180153/1 "2009-12-13T14:21:48Z")

</div>

Hi,

I’m using this assertion in a functional test:

assert\_redirected\_to facturas\_path(assigns(:factura))

and I’m getting this error:

1. Failure:  
test\_actualizar\_plazos\_factura(FacturasControllerTest)  
[/test/functional/facturas\_controller\_test.rb:329]:  
Expected response to be a redirect to  
[http://test.host/facturas.%23\<facturaemitida:0x535cdfc\>](http://test.host/facturas.%23%3Cfacturaemitida:0x535cdfc%3E) but was a  
redirect t  
o [http://test.host/facturas/731476621](http://test.host/facturas/731476621).

In the controller I’m using this redirection:

redirect\_to factura\_url(@factura)

And in the routes file I have this:

map.resources :facturas  
map.resources :facturas\_emitidas, :controller =\> ‘facturas’  
map.resources :facturas\_proforma, :controller =\> ‘facturas’  
map.resources :facturas\_recibidas, :controller =\> ‘facturas’

Any idea?
