return $conn->remote_object(class => $class, args => \@args);
}
+sub can::on {
+ my ($class, $on, $name) = @_;
+ my $conn = __PACKAGE__->connect($on);
+ return $conn->remote_sub(join('::', $class, $name));
+}
+
sub new {
shift;
Object::Remote::Handle->new(@_)->proxy;
is($x, 1, "Callback called callback");
is(
- $connection->remote_sub('Sys::Hostname::hostname')->(),
+ Sys::Hostname->can::on($connection, 'hostname')->(),
hostname(),
'Remote sub call ok'
);