/[A3C]/t/50-strix.t
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Annotation of /t/50-strix.t

Parent Directory Parent Directory | Revision Log Revision Log


Revision 174 - (hide annotations)
Mon Jun 16 16:48:16 2008 UTC (14 years ago) by dpavlin
File MIME type: application/x-troff
File size: 835 byte(s)
big rename of StrixSite to StrixInstance, added sitemap and layout

rename creates huge diff, which is rather unfortunate, but we needed
to get terminology stright: sites are part of strix instances
1 dpavlin 168 #!/usr/bin/env perl
2     use warnings;
3     use strict;
4    
5     =head1 DESCRIPTION
6    
7     test Strix integration
8    
9     =cut
10    
11 dpavlin 169 use Jifty::Test tests => 10;
12 dpavlin 168
13     use Data::Dump qw/dump/;
14    
15     use_ok('Strix');
16    
17     $Strix::debug = 1 if @ARGV;
18     my $debug = $Strix::debug;
19    
20 dpavlin 174 my $instance = 'os-test0604-zg';
21     $instance = 'new';
22 dpavlin 168
23 dpavlin 174 ok( my $dbh = Strix->dbh( $instance ), 'dbh' );
24 dpavlin 168 isa_ok( $dbh, 'DBI::db' );
25    
26 dpavlin 174 ok( my $strix = Strix->new({ instance => $instance }), 'new' );
27 dpavlin 168 isa_ok( $strix, 'Strix' );
28    
29     my $url = '/';
30    
31     ok( my $category = $strix->category( $url ), "category $url" );
32     diag dump( $category ) if $debug;
33    
34    
35     ok( my $layout = $strix->layout( $url ), "layout $url" );
36     diag dump( $layout ) if $debug;
37     ok( $layout->{pre}, 'pre' );
38     ok( $layout->{free}, 'free' );
39 dpavlin 169
40     my $site_id = 1;
41    
42     ok( my $sitemap = $strix->sitemap( $site_id ), "sitemap $site_id" );
43     diag dump( $sitemap ) if $debug;

Properties

Name Value
svn:executable *

  ViewVC Help
Powered by ViewVC 1.1.26