blib/lib/Finance/Robinhood/Account.pm

filter: Statementstmt 80.7% 21 / 26 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 62.5% 5 / 8 Podpod n/a totaltotal 76.4% 26 / 34 CC 1 SCAR 1.5
CC
1
Cov
81%
__ANON__
2.0
__ANON__
1.1
__ANON__
1.1
CRAP 1.2
« blib/lib/Finance/Robinhood/Options/Event/EquityComponent.pm ↑ Summary blib/lib/Finance/Robinhood/Utils/Error.pm »
1 package Finance::Robinhood::Account;
2 3 ▶use Moo;
Subroutine BEGIN: called CC=1 SCAR=0.0
3 3 with 'MooX::Singleton';
4 3 ▶use DateTime::Tiny;
Subroutine BEGIN: called CC=1 SCAR=0.0
5 3 ▶use Date::Tiny;
Subroutine BEGIN: called CC=1 SCAR=0.0
6 #
7 3 ▶use Finance::Robinhood::Account::InstantEligibility;
Subroutine BEGIN: called CC=1 SCAR=0.0
8 3 use Finance::Robinhood::Account::MarginBalances has [
9 qw[account_number buying_power
10 cash cash_available_for_withdrawl cash_balances cash_held_for_orders
11 deactivated deposit_halted
12 max_ach_early_access_amount
13 only_position_closing_trades
14 option_level sma sma_held_for_orders sweep_enabled type uncleared_deposits
15 unsettled_debt unsettled_funds url withdrawal_halted
16 ]
17 3 ▶] => ( is => 'ro' );
Subroutine BEGIN: called CC=1 SCAR=0.0
18 has 'instant_eligibility' =>
19 0 ▶ ( is => 'ro', coerce => sub { Finance::Robinhood::Account::InstantEligibility->new( $_[0] ) } );
Subroutine __ANON__: not called CC=1 SCAR=1.2
20 has 'margin_balances' =>
21 0 ▶ ( is => 'ro', coerce => sub { Finance::Robinhood::Account::MarginBalances->new( $_[0] ) } );
Subroutine __ANON__: not called CC=1 SCAR=1.2
22 has [ 'created_at', 'updated_at' ] => (
23 is => 'ro',
24 coerce => sub {
25 0 ▶ $_[0] =~ s'Z$'';
Subroutine __ANON__: not called CC=1 SCAR=6.9
26  
27 # BUG: DateTime::Tiny cannot handle sub-second values.
28 0 $_[0] =~ s'\..+$'';
29 0 DateTime::Tiny->from_string( $_[0] );
30 }
31 3 );
32 3 has [
33 qw[can_downgrade_to_cash portfolio positions
34 ]
35 ] => ( is => 'ro' );
36 3 1;
« blib/lib/Finance/Robinhood/Options/Event/EquityComponent.pm ↑ Summary blib/lib/Finance/Robinhood/Utils/Error.pm »