Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Catalyst: Dev

uri_for() with '0' value

 

 

Catalyst dev RSS feed   Index | Next | Previous | View Threaded


peter at peknet

Feb 1, 2008, 9:44 AM

Post #1 of 3 (608 views)
Permalink
uri_for() with '0' value

Here's a failing test patch for uri_for against
http://dev.catalyst.perl.org/repos/Catalyst/branches/current/Catalyst-Runtime

Not sure of the cause. Just passing along the news. I will send a patch to fix it when/if
I can.



--- t/unit_core_uri_for.t (revision 7426)
+++ t/unit_core_uri_for.t (working copy)
@@ -1,7 +1,7 @@
use strict;
use warnings;

-use Test::More tests => 13;
+use Test::More tests => 14;
use URI;

use_ok('Catalyst');
@@ -33,7 +33,13 @@
'URI for undef action with args'
);

+is(
+ Catalyst::uri_for( $context, 0, 'arg1', 'arg2' )->as_string,
+ 'http://127.0.0.1/foo/yada/0/arg1/arg2',
+ 'URI for undef action with args 0'
+);

+
is( Catalyst::uri_for( $context, '../quux' )->as_string,
'http://127.0.0.1/foo/quux', 'URI for relative dot path' );
--
Peter Karman . peter[at]peknet.com . http://peknet.com/


_______________________________________________
Catalyst-dev mailing list
Catalyst-dev[at]lists.scsys.co.uk
http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst-dev


brian.cassidy at nald

Feb 1, 2008, 11:41 AM

Post #2 of 3 (565 views)
Permalink
Re: uri_for() with '0' value [In reply to]

Peter Karman wrote:
> Here's a failing test patch for uri_for against
> http://dev.catalyst.perl.org/repos/Catalyst/branches/current/Catalyst-Runtime

Hrmm, trunk [1] already seems to have a test against "0" in a path [2]:

# test "0" as the path
is( Catalyst::uri_for( $context, qw/0 foo/ )->as_string,
'http://127.0.0.1/0/foo', '0 as path is ok'
);

It seems to pass just fine.

-Brian

[1] http://dev.catalyst.perl.org/repos/Catalyst/Catalyst-Runtime/5.70/trunk
[2]
http://dev.catalyst.perl.org/repos/Catalyst/Catalyst-Runtime/5.70/trunk/t/unit_core_uri_for.t

_______________________________________________
Catalyst-dev mailing list
Catalyst-dev[at]lists.scsys.co.uk
http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst-dev


dbix-class at trout

Feb 1, 2008, 10:41 PM

Post #3 of 3 (560 views)
Permalink
Re: uri_for() with '0' value [In reply to]

On Fri, Feb 01, 2008 at 11:44:57AM -0600, Peter Karman wrote:
> Here's a failing test patch for uri_for against
> http://dev.catalyst.perl.org/repos/Catalyst/branches/current/Catalyst-Runtime

branches/current is dead. Long dead. I'll go delete it.

Catalyst-Runtime/5.70/trunk is where to bugfix against.

Catalyst-Runtime/5.80/trunk will be the new current once 5.80 dev gets
rolling properly.

--
Matt S Trout Need help with your Catalyst or DBIx::Class project?
Technical Director http://www.shadowcat.co.uk/catalyst/
Shadowcat Systems Ltd. Want a managed development or deployment platform?
http://chainsawblues.vox.com/ http://www.shadowcat.co.uk/servers/

_______________________________________________
Catalyst-dev mailing list
Catalyst-dev[at]lists.scsys.co.uk
http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst-dev

Catalyst dev RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact lists@gossamer-threads.com
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.