lib/WebService/Braintree/DocumentUploadGateway.pm

filter: Statementstmt 86.9% 20 / 23 Branchbran 0.0% 0 / 2 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 85.7% 6 / 7 Podpod 0.0% 0 / 1 totaltotal 78.7% 26 / 33 CC 2 SCAR 8.1
CC
2
Cov
80%
create
6.0
BEGIN
1.0
BEGIN
1.0
CRAP 2.2
« lib/WebService/Braintree/_/WebhookNotification.pm ↑ Summary lib/WebService/Braintree/EuropeBankAccountGateway.pm »
1 # vim: sw=4 ts=4 ft=perl
2  
3 package # hide from pause
4 WebService::Braintree::DocumentUploadGateway;
5  
6 22 ▶use 5.010_001;
Subroutine BEGIN: called CC=1 SCAR=0.0
7 22 ▶use strictures 1;
Subroutine BEGIN: called CC=1 SCAR=0.0
8  
9 22 ▶use Moo;
Subroutine BEGIN: called CC=1 SCAR=0.0
10 22 with 'WebService::Braintree::Role::MakeRequest';
11  
12 22 ▶use Carp qw(confess);
Subroutine BEGIN: called CC=1 SCAR=0.0
13  
14 22 ▶use WebService::Braintree::Validations qw(verify_params);
Subroutine BEGIN: called CC=1 SCAR=0.0
15  
16 22 ▶use WebService::Braintree::_::DocumentUpload;
Subroutine BEGIN: called CC=1 SCAR=0.0
17  
18 0 ▶sub create {
Subroutine create: not called CC=2 SCAR=17.9
Pod undocumented
19 0 my ($self, $params) = @_;
20  
21 0 ▶ confess "ArgumentError" unless verify_params($params, {
Branch: 1 branch
BranchTrueFalseTotal
unless verify_params($params, {"file", 1, "kind", 1}) 0 0 0
22 file => 1,
23 kind => 1,
24 });
25  
26 $self->_make_request("/document_uploads", "post", {
27 'document_upload[kind]' => $params->{kind},
28 0 }, $params->{file});
29 }
30  
31 22 __PACKAGE__->meta->make_immutable;
32  
33 22 1;
34 __END__
« lib/WebService/Braintree/_/WebhookNotification.pm ↑ Summary lib/WebService/Braintree/EuropeBankAccountGateway.pm »