Passed
Push — main ( d5b4d9...0df0a9 )
by PRATIK
04:50 queued 01:52
created

DateConverterTestDouble::getTotalEnglishDays()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
eloc 1
c 1
b 0
f 0
nc 1
nop 3
dl 0
loc 3
rs 10
1
<?php
2
3
namespace Pratiksh\Nepalidate\Tests\Unit\Doubles;
4
5
use Pratiksh\Nepalidate\Services\DateConverter;
6
7
class DateConverterTestDouble extends DateConverter
8
{
9
    // Expose protected methods for testing
10
    public function isInRangeEng($yy, $mm, $dd)
11
    {
12
        return $this->is_in_range_eng($yy, $mm, $dd);
13
    }
14
15
    public function isInRangeNep($yy, $mm, $dd)
16
    {
17
        return $this->is_in_range_nep($yy, $mm, $dd);
18
    }
19
20
    public function isLeapYear($year)
21
    {
22
        return $this->is_leap_year($year);
23
    }
24
25
    public function getTotalEnglishDays($year, $month, $day)
26
    {
27
        return $this->calculateTotalEnglishDays($year, $month, $day);
28
    }
29
30
    public function getTotalNepaliDays($year, $month, $day)
31
    {
32
        return $this->calculateTotalNepaliDays($year, $month, $day);
33
    }
34
35
    public function getCalendarData()
36
    {
37
        return $this->calendarData;
38
    }
39
}
40