]> git.donarmstrong.com Git - debbugs.git/blobdiff - t/09_soap.t
fix corner case where Debbugs::Versions would return positive or negative numbers
[debbugs.git] / t / 09_soap.t
index 2ffd45c2dc15add62f083f3dde3c4facbdca250a..2a04c60e07da530176262ced80b81d4150a16690 100644 (file)
@@ -6,13 +6,6 @@ use Test::More tests => 4;
 use warnings;
 use strict;
 
-# Here, we're going to shoot messages through a set of things that can
-# happen.
-
-# First, we're going to send mesages to receive.
-# To do so, we'll first send a message to submit,
-# then send messages to the newly created bugnumber.
-
 use IO::File;
 use File::Temp qw(tempdir);
 use Cwd qw(getcwd);
@@ -32,7 +25,7 @@ if ($@) {
      BAIL_OUT($@);
 }
 
-# Output some debugging information if there's an error
+# Output some debugging information if we're debugging
 END{
      if ($ENV{DEBUG}) {
          foreach my $key (keys %config) {
@@ -55,9 +48,9 @@ This is a silly bug
 EOF
 
 
-# test bugreport.cgi
+# test the soap server
 
-my $port = 11342;
+my $port = 11343;
 
 # We'd like to use soap.cgi here instead of testing the module
 # directly, but I can't quite get it to work with
@@ -69,8 +62,10 @@ our $child_pid = undef;
 
 END{
      if (defined $child_pid) {
+         my $temp_exit = $?;
          kill(15,$child_pid);
          waitpid(-1,0);
+         $? = $temp_exit;
      }
 }
 
@@ -78,8 +73,8 @@ my $pid = fork;
 die "Unable to fork child" if not defined $pid;
 if ($pid) {
      $child_pid = $pid;
-     # Wait for a second to let the child start
-     sleep 1;
+     # Wait for two seconds to let the child start
+     sleep 2;
 }
 else {
      # UGH.