IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
May 2, 2007, 5:21:28 PM (19 years ago)
Author:
jhoblitt
Message:

overhaul Nebulous::Client->cull()
add the number of instances to ->stat_object()

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Nebulous/t/09_server_stat_object.t

    r13092 r13180  
    33# Copryight (C) 2004-2005  Joshua Hoblitt
    44#
    5 # $Id: 09_server_stat_object.t,v 1.10 2007-05-01 02:52:04 jhoblitt Exp $
     5# $Id: 09_server_stat_object.t,v 1.11 2007-05-03 03:21:28 jhoblitt Exp $
    66
    77use strict;
    88use warnings FATAL => qw( all );
    99
    10 use Test::More tests => 11;
     10use Test::More tests => 12;
    1111
    1212use lib qw( ./t ./lib );
     
    2323
    2424Test::Nebulous->setup;
    25 
    2625{
    27     my $uri = $neb->create_object("foo");
     26    $neb->create_object("foo");
    2827
    2928    my $info = $neb->stat_object("foo");
    3029
    31     is(scalar @$info, 6, "number of columns");
     30    is(scalar @$info, 7, "number of columns");
    3231}
    3332
     
    3534
    3635{
    37     my $uri = $neb->create_object("foo", "node01");
     36    $neb->create_object("foo", "node01");
    3837
    3938    my $info = $neb->stat_object("foo");
    4039
    41     is(scalar @$info, 6,                       "number of columns");
     40    is(scalar @$info, 7,                       "number of columns");
    4241    is(@$info[0], 1,                           "so_id");
    4342    is(@$info[1], "foo",                       "ext_id");
     
    4645    like(@$info[4], qr/....-..-.. ..:..:../,   "epoch");
    4746    like(@$info[5], qr/....-..-.. ..:..:../,   "mtime");
     47    is(@$info[6], 1,                           "instances");
    4848}
    4949
     
    5353    $neb->stat_object("foo");
    5454};
    55 like($@, qr/no storage object found/, "object does not exist");
     55like($@, qr/is valid object key/, "object does not exist");
    5656
    5757Test::Nebulous->setup;
     
    6565
    6666eval {
     67    $neb->create_object("foo");
    6768    $neb->stat_object("foo", 2);
    6869};
Note: See TracChangeset for help on using the changeset viewer.