projects
/
MojoX-Gearman.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
first worker
[MojoX-Gearman.git]
/
t
/
gearman.t
diff --git
a/t/gearman.t
b/t/gearman.t
index
9a3c60c
..
4df77c5
100755
(executable)
--- a/
t/gearman.t
+++ b/
t/gearman.t
@@
-2,12
+2,20
@@
use warnings;
use strict;
use warnings;
use strict;
-use Test::More tests => 4;
+use Test::More tests => 7;
+use Data::Dump qw(dump);
use lib 'lib';
use_ok 'MojoX::Gearman';
my $g = new_ok 'MojoX::Gearman';
use lib 'lib';
use_ok 'MojoX::Gearman';
my $g = new_ok 'MojoX::Gearman';
-ok( my $echo = $g->req(
16, "foobar" ), 'echo
' );
+ok( my $echo = $g->req(
'ECHO_REQ', "foobar" ), 'ECHO
' );
cmp_ok $echo, 'eq', "foobar";
cmp_ok $echo, 'eq', "foobar";
+
+ok( my $ping = $g->req( 'SUBMIT_JOB', 'ping', '', 'bla' ), 'SUBMIT_JOB' );
+like $ping, qr/pong/, 'got pong';
+diag dump $ping;
+
+ok( $g->req( 'ECHO_REQ', "alive" ), 'ECHO - still alive - still alive?' );
+