/[Search-TokyoDystopia]/t/11-tcq.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

Diff of /t/11-tcq.t

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 32 by dpavlin, Tue Sep 2 16:13:06 2008 UTC revision 34 by dpavlin, Tue Sep 9 13:17:16 2008 UTC
# Line 5  use strict; Line 5  use strict;
5    
6  use blib;  use blib;
7    
8  use Test::More tests => 34;  use Test::More tests => 30;
9  use Test::Exception;  use Test::Exception;
10  use Data::Dump qw/dump/;  use Data::Dump qw/dump/;
11    
# Line 44  ok( tcqdbopen( $qdb, $path, QDBOWRITER | Line 44  ok( tcqdbopen( $qdb, $path, QDBOWRITER |
44    
45  ok( tcqdbput( $qdb, 1, 'foobar' ), 'tcqdbput' );  ok( tcqdbput( $qdb, 1, 'foobar' ), 'tcqdbput' );
46    
47  ok( tcqdbout( $qdb, 1, ), 'tcqdbout' );  ok( tcqdbout( $qdb, 1, 'foobar' ), 'tcqdbout' );
48    
49  ok( tcqdbput( $qdb, 42, 'some data' ), 'tcqdbput again' );  ok( tcqdbput( $qdb, 42, 'some data' ), 'tcqdbput again' );
50    
# Line 63  ok( -e $copy_path, 'copy exists' ); Line 63  ok( -e $copy_path, 'copy exists' );
63    
64  is( tcqdbpath( $qdb ), $path, 'tcqdbpath' );  is( tcqdbpath( $qdb ), $path, 'tcqdbpath' );
65    
66  is( tcqdbtnum( $qdb ), 2, 'tcqdbtnum' );  is( tcqdbtnum( $qdb ), 13, 'tcqdbtnum' );
67    
68  ok( my $file_size = tcqdbfsiz( $qdb ), 'tcqdbfsiz' );  ok( my $file_size = tcqdbfsiz( $qdb ), 'tcqdbfsiz' );
69    
# Line 71  ok( tcqdbvanish( $qdb ), 'tcqdbvanish' ) Line 71  ok( tcqdbvanish( $qdb ), 'tcqdbvanish' )
71    
72  is( tcqdbtnum( $qdb ), 0, 'tcqdbtnum' );  is( tcqdbtnum( $qdb ), 0, 'tcqdbtnum' );
73    
74  cmp_ok( tcqdbfsiz( $qdb ), '<', $file_size, 'tcqdbfsiz' );  cmp_ok( tcqdbfsiz( $qdb ), '<=', $file_size, 'tcqdbfsiz' );
75    
76  diag tcqdberrmsg( tcqdbecode( $qdb ) );  diag tcqdberrmsg( tcqdbecode( $qdb ) );

Legend:
Removed from v.32  
changed lines
  Added in v.34

  ViewVC Help
Powered by ViewVC 1.1.26