AnsibleModule
view release on metacpan or search on metacpan
script/ansible-perl view on Meta::CPAN
$ENV{ANSIBLE_ARGS} ||="{}";
my $t=Test::AnsibleModule->new;
my $res=$t->exec_module($ENV{ANSIBLE_MODULE},decode_json($ENV{ANSIBLE_ARGS}));
print "Output from $ENV{ANSIBLE_MODULE}: ". dumper($t->last_response);
print "Response code: $res\n";
=encoding utf8
=head1 NAME
test_ansible_module - Test ansible modules on the command line
=head1 SYNOPSIS
Usage: test_ansible_module -m module_path -a arguments
test_ansible_module -m echo -a hello=world
( run in 1.389 second using v1.01-cache-2.11-cpan-49f99fa48dc )