/[pxelator]/lib/PXElator/t/CouchDB.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 /lib/PXElator/t/CouchDB.t

Parent Directory Parent Directory | Revision Log Revision Log


Revision 206 - (hide annotations)
Wed Aug 12 22:27:57 2009 UTC (14 years, 9 months ago) by dpavlin
File MIME type: application/x-troff
File size: 452 byte(s)
better encode json and add some x_meta data
1 dpavlin 205 #!/usr/bin/perl
2    
3     use warnings;
4     use strict;
5     use autodie;
6    
7 dpavlin 206 use Test::More tests => 5;
8 dpavlin 205 use Data::Dump qw/dump/;
9    
10     use_ok 'CouchDB';
11    
12     my $db = 'pxelator';
13     my $url = "$db/test";
14    
15     ok( my $db = CouchDB->new(), 'new' );
16    
17     ok( $db->put( $url, { foo => 42, bar => 'baz' }), "put $url" );
18    
19     ok( my $doc = $db->get( $url, 'get' ), 'get' );
20    
21     diag dump( $doc );
22    
23     #ok( $db->delete( "$db" ), 'delete' );
24    
25 dpavlin 206 ok( $db->audit( 'test', { foo => 42, bar => 'baz' }), 'audit' );

Properties

Name Value
svn:executable *

  ViewVC Help
Powered by ViewVC 1.1.26