X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=scpubgit%2FObject-Remote.git;a=blobdiff_plain;f=t%2Fsender.t;h=d8b58e2ac69b73c43a9cacbf6b157f05a4b8161d;hp=8916297452ebfda73214af34790fbc8192d51f62;hb=a711172670b40e3a6033791ef6a747031ec7464b;hpb=542d5b5ca3990695be389d0d497883876c189486 diff --git a/t/sender.t b/t/sender.t index 8916297..d8b58e2 100644 --- a/t/sender.t +++ b/t/sender.t @@ -9,29 +9,25 @@ $ENV{PERL5LIB} = join( ':', ($ENV{PERL5LIB} ? $ENV{PERL5LIB} : ()), qw(lib) ); -my $connection = Object::Remote::Connector::Local->new->connect; - my $ms = Object::Remote::ModuleSender->new( dir_list => [ 't/lib' ] ); -my $ml = Object::Remote->new( - connection => $connection, - class => 'Object::Remote::ModuleLoader', - args => { module_sender => $ms }, -); +my $connection = Object::Remote::Connector::Local->new( + module_sender => $ms, + )->connect; -my $proxy = Object::Remote->new( +my $counter = Object::Remote->new( connection => $connection, class => 'ORTestClass' -)->proxy; +); -isnt($$, $proxy->pid, 'Different pid on the other side'); +isnt($$, $counter->pid, 'Different pid on the other side'); -is($proxy->counter, 0, 'Counter at 0'); +is($counter->counter, 0, 'Counter at 0'); -is($proxy->increment, 1, 'Increment to 1'); +is($counter->increment, 1, 'Increment to 1'); -is($proxy->counter, 1, 'Counter at 1'); +is($counter->counter, 1, 'Counter at 1'); done_testing;