lib/auto/share/dist/Amazon-SQS-Client/CreateQueue.pm untested

filter: Statementstmt 0.0% 0 / 38 Branchbran 0.0% 0 / 10 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 0.0% 0 / 8 Podpod 0.0% 0 / 1 totaltotal 0.0% 0 / 57 CC 6 SCAR 30.2
CC
6
Cov
0%
sample
42.0
BEGIN
2.0
BEGIN
2.0
CRAP 20.5
1 package CreateQueue;
2  
3 use strict;
4 use warnings;
5  
6 use Amazon::SQS::Model::CreateQueueRequest;
7  
8 use English qw(-no_match_vars);
9 use JSON;
10 use Data::Dumper;
11  
12 use parent qw(Amazon::SQS::Sample);
13  
14 ########################################################################
15 sub sample {
16 ########################################################################
17 my ($self, $queue_name) = @_;
18
19 die "usage: example.pl [-f config-name] CreateQueue queue-name\n"
20 if !$queue_name;
21  
22 my $service = $self->get_service;
23  
24 my $response = $service->createQueue( { QueueName => $queue_name } );
25  
26 if ( $response->isSetCreateQueueResult() ) {
27  
28 my $createQueueResult = $response->getCreateQueueResult();
29  
30 if ( $createQueueResult->isSetQueueUrl() ) {
31 print {*STDOUT} Dumper( [ queueUrl => $createQueueResult->getQueueUrl() ] );
32 }
33 }
34  
35 if ( $response->isSetResponseMetadata() ) {
36 my $responseMetadata = $response->getResponseMetadata();
37  
38 if ( $responseMetadata->isSetRequestId() ) {
39 my $requestId = $responseMetadata->getRequestId();
40 }
41 }
42  
43 return;
44 }
45  
46 1;
47  
48 ## no critic
49  
50 __END__