Changeset f387f75fc42c18a92cc4f5b9c14bba9ea420b842

Show
Ignore:
Timestamp:
01/10/10 05:07:39 (4 years ago)
Author:
Theo Schlossnagle <jesus@omniti.com>
git-committer:
Theo Schlossnagle <jesus@omniti.com> 1263100059 +0000
git-parent:

[12ef579a4576c2d52bc65063b48858887e0669da]

git-author:
Theo Schlossnagle <jesus@omniti.com> 1263100059 +0000
Message:

fixes for the apiclient, caused a bit of a wild goose chase. refs #230

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • test/t/003_simple_noit.t

    r5715632 rf387f75  
    99my $xpc = XML::LibXML::XPathContext->new(); 
    1010 
    11 ok(start_noit("003", { modules => $all_noit_modules }), 'starting noit'); 
     11ok(start_noit("003", { logs_debug => { '' => 'false' } }), 'starting noit'); 
    1212sleep(1); 
    1313my $c = apiclient->new('localhost', $NOIT_API_PORT); 
     
    2424 
    2525sleep(1); 
    26 $c = apiclient->new('localhost', $NOIT_API_PORT); 
    2726@r = $c->get("/checks/show/f7cea020-f19d-11dd-85a6-cb6d3a2207dc"); 
    2827is($r[0], 200, 'get checks'); 
  • test/t/apiclient.pm

    r5715632 rf387f75  
    2626        $self->{curl}->setopt(CURLOPT_INFILESIZE, length($payload)); 
    2727    } 
     28    else { 
     29        $self->{curl}->setopt(CURLOPT_UPLOAD, 0); 
     30    } 
    2831    $self->{curl}->setopt(CURLOPT_CUSTOMREQUEST, $method); 
    2932    $self->{curl}->setopt(CURLOPT_URL, "https://$self->{host}:$self->{port}$uri"); 
  • test/t/testconfig.pm

    r5715632 rf387f75  
    116116  my ($o, $opts) = @_; 
    117117  my $cwd = $opts->{cwd}; 
     118  $opts->{modules} = $all_noit_modules unless exists($opts->{modules}); 
    118119  print $o qq{ 
    119120  <modules directory="$cwd/../../src/modules"> 
     
    212213  my $cwd = $options->{cwd}; 
    213214  my $file = "$cwd/logs/${name}_noit.conf"; 
    214   open (my $o, ">$file")
     215  open (my $o, ">$file") || BAIL_OUT("can't write config: $file")
    215216  print $o qq{<?xml version="1.0" encoding="utf8" standalone="yes"?>\n}; 
    216217  print $o qq{<noit>};