blib/lib/WWW/Shopify/Model/Discount.pm

filter: Statementstmt 34.5% 19 / 55 Branchbran 3.1% 1 / 32 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 26.9% 7 / 26 Podpod 23.8% 5 / 21 totaltotal 23.8% 32 / 134 CC 16 SCAR 14.8
CC
16
Cov
23%
applies_once
5.5
applies_to_id
5.5
applies_to_resource
5.5
CRAP 4.4
« blib/lib/WWW/Shopify/Private.pm ↑ Summary blib/lib/WWW/Shopify/Model/RecurringApplicationCharge.pm »
1 #!/usr/bin/perl
2  
3 1 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 1 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
5  
6 1 ▶use WWW::Shopify;
Subroutine BEGIN: called CC=1 SCAR=0.0
7  
8 package WWW::Shopify::Model::Discount;
9 1 ▶use parent "WWW::Shopify::Model::Item";
Subroutine BEGIN: called CC=1 SCAR=0.0
10  
11 44 ▶my $fields; sub fields { return $fields; }
Subroutine fields: called CC=1 SCAR=0.0
Pod documented
12 1 ▶BEGIN { $fields = {
Subroutine BEGIN: called CC=1 SCAR=0.0
13 "applies_once" => new WWW::Shopify::Field::Boolean(),
14 "code" => new WWW::Shopify::Field::String(),
15 "ends_at" => new WWW::Shopify::Field::Date(min => '2010-01-01 00:00:00', max => 'now'),
16 "starts_at" => new WWW::Shopify::Field::Date(min => '2010-01-01 00:00:00', max => 'now'),
17 "id" => new WWW::Shopify::Field::Identifier(),
18 "minimum_order_amount" => new WWW::Shopify::Field::Money(),
19 "status" => new WWW::Shopify::Field::String::Enum(["enabled", "disabled"]),
20 "usage_limit" => new WWW::Shopify::Field::Int(),
21 "value" => new WWW::Shopify::Field::Money(),
22 "discount_type" => new WWW::Shopify::Field::String::Enum(["fixed_amount", "percentage"]),
23 "applies_to_resource" => new WWW::Shopify::Field::String::Enum(["order", "product", "collection", "customer_group"]),
24 "times_used" => new WWW::Shopify::Field::Int(),
25 "applies_to_id" => new WWW::Shopify::Field::Relation::ReferenceOne("WWW::Shopify::Model::Product")
26 }; }
27  
28 0 ▶sub creation_minimal { return qw(discount_type code value); }
Subroutine creation_minimal: not called CC=1 SCAR=6.9
Pod documented
29 0 ▶sub creation_filled { return qw(status); }
Subroutine creation_filled: not called CC=1 SCAR=6.9
Pod documented
30 0 ▶sub update_filled { return qw(); }
Subroutine update_filled: not called CC=1 SCAR=6.9
Pod documented
31  
32 1 ▶sub actions { return qw(disable enable); }
Subroutine actions: called CC=1 SCAR=0.0
Pod documented
33  
34 0 ▶sub needs_login { return 1; }
Subroutine needs_login: not called CC=1 SCAR=6.9
Pod undocumented
35  
36 0 ▶eval(__PACKAGE__->generate_accessors); die $@ if $@;
Subroutine applies_once: not called CC=2 SCAR=17.0
Subroutine applies_to_id: not called CC=2 SCAR=17.0
Subroutine applies_to_resource: not called CC=2 SCAR=17.0
Subroutine code: not called CC=2 SCAR=17.0
Subroutine disable: not called CC=2 SCAR=17.0
Subroutine discount_type: not called CC=2 SCAR=17.0
Subroutine enable: not called CC=2 SCAR=17.0
Subroutine ends_at: not called CC=2 SCAR=17.0
Subroutine id: not called CC=2 SCAR=17.0
Subroutine minimum_order_amount: not called CC=2 SCAR=17.0
Subroutine starts_at: not called CC=2 SCAR=17.0
Subroutine status: not called CC=2 SCAR=17.0
Subroutine times_used: not called CC=2 SCAR=17.0
Subroutine usage_limit: not called CC=2 SCAR=17.0
Subroutine value: not called CC=2 SCAR=17.0
Pod undocumented
Pod undocumented
Pod undocumented
Pod undocumented
Pod undocumented
Pod undocumented
Pod undocumented
Pod undocumented
Pod undocumented
Pod undocumented
Pod undocumented
Pod undocumented
Pod undocumented
Pod undocumented
Pod undocumented
Branch: 16 branches
BranchTrueFalseTotal
if defined $_[1] 0 0 0
if defined $_[1] 0 0 0
if defined $_[1] 0 0 0
if defined $_[1] 0 0 0
unless $sa 0 0 0
if defined $_[1] 0 0 0
unless $sa 0 0 0
if defined $_[1] 0 0 0
if defined $_[1] 0 0 0
if defined $_[1] 0 0 0
if defined $_[1] 0 0 0
if defined $_[1] 0 0 0
if defined $_[1] 0 0 0
if defined $_[1] 0 0 0
if defined $_[1] 0 0 0
if $@ 0 1 1
37  
38 1 1;
« blib/lib/WWW/Shopify/Private.pm ↑ Summary blib/lib/WWW/Shopify/Model/RecurringApplicationCharge.pm »