check_pop.t 615 B

12345678910111213141516171819202122232425262728293031
  1. #! /usr/bin/perl -w
  2. #use strict;
  3. use Cache;
  4. use Test;
  5. use vars qw($tests);
  6. BEGIN {$tests = 3; plan tests => $tests}
  7. my $null = '';
  8. my $cmd;
  9. my $str;
  10. my $t;
  11. $cmd = "./check_pop $Cache::mailhost";
  12. $str = `$cmd`;
  13. $t += ok $?>>8,0;
  14. print "Test was: $cmd\n" if ($?);
  15. $cmd = "./check_pop -H $Cache::mailhost -p 110 -w 9 -c 9 -t 10 -e '+OK'";
  16. $str = `$cmd`;
  17. $t += ok $?>>8,0;
  18. print "Test was: $cmd\n" if ($?);
  19. $cmd = "./check_pop $Cache::mailhost -p 110 -wt 9 -ct 9 -to 10 -e '+OK'";
  20. $str = `$cmd`;
  21. $t += ok $?>>8,0;
  22. print "Test was: $cmd\n" if ($?);
  23. exit(0) if defined($Test::Harness::VERSION);
  24. exit($tests - $t);