@@ -49,7 +49,7 @@ discard block |
||
49 | 49 | /** |
50 | 50 | * Load Calendar base class. |
51 | 51 | */ |
52 | -require_once CALENDAR_ROOT . 'Calendar.php'; |
|
52 | +require_once CALENDAR_ROOT.'Calendar.php'; |
|
53 | 53 | |
54 | 54 | /** |
55 | 55 | * Represents a Day and builds Hours. |
@@ -113,7 +113,7 @@ discard block |
||
113 | 113 | */ |
114 | 114 | public function build($sDates = []) |
115 | 115 | { |
116 | - require_once CALENDAR_ROOT . 'Hour.php'; |
|
116 | + require_once CALENDAR_ROOT.'Hour.php'; |
|
117 | 117 | |
118 | 118 | $hID = $this->cE->getHoursInDay($this->year, $this->month, $this->day); |
119 | 119 | for ($i = 0; $i < $hID; ++$i) { |
@@ -137,7 +137,7 @@ discard block |
||
137 | 137 | foreach ($sDates as $sDate) { |
138 | 138 | if ($this->year == $sDate->thisYear() && $this->month == $sDate->thisMonth() |
139 | 139 | && $this->day == $sDate->thisDay()) { |
140 | - $key = (int)$sDate->thisHour(); |
|
140 | + $key = (int) $sDate->thisHour(); |
|
141 | 141 | if (isset($this->children[$key])) { |
142 | 142 | $sDate->setSelected(); |
143 | 143 | $this->children[$key] = $sDate; |
@@ -50,12 +50,12 @@ discard block |
||
50 | 50 | /** |
51 | 51 | * Load Calendar base class. |
52 | 52 | */ |
53 | -require_once CALENDAR_ROOT . 'Calendar.php'; |
|
53 | +require_once CALENDAR_ROOT.'Calendar.php'; |
|
54 | 54 | |
55 | 55 | /** |
56 | 56 | * Load base month. |
57 | 57 | */ |
58 | -require_once CALENDAR_ROOT . 'Month.php'; |
|
58 | +require_once CALENDAR_ROOT.'Month.php'; |
|
59 | 59 | |
60 | 60 | /** |
61 | 61 | * Represents a Month and builds Weeks |
@@ -116,9 +116,9 @@ discard block |
||
116 | 116 | */ |
117 | 117 | public function build($sDates = []) |
118 | 118 | { |
119 | - require_once CALENDAR_ROOT . 'Table/Helper.php'; |
|
119 | + require_once CALENDAR_ROOT.'Table/Helper.php'; |
|
120 | 120 | $this->tableHelper = new Calendar_Table_Helper($this, $this->firstDay); |
121 | - require_once CALENDAR_ROOT . 'Week.php'; |
|
121 | + require_once CALENDAR_ROOT.'Week.php'; |
|
122 | 122 | $numWeeks = $this->tableHelper->getNumWeeks(); |
123 | 123 | for ($i = 1, $d = 1; $i <= $numWeeks; ++$i, $d += $this->cE->getDaysInWeek($this->thisYear(), $this->thisMonth(), $this->thisDay())) { |
124 | 124 | $this->children[$i] = new Calendar_Week($this->year, $this->month, $d, $this->tableHelper->getFirstDay()); |
@@ -49,12 +49,12 @@ discard block |
||
49 | 49 | /** |
50 | 50 | * Load Calendar base class. |
51 | 51 | */ |
52 | -require_once CALENDAR_ROOT . 'Calendar.php'; |
|
52 | +require_once CALENDAR_ROOT.'Calendar.php'; |
|
53 | 53 | |
54 | 54 | /** |
55 | 55 | * Load base month. |
56 | 56 | */ |
57 | -require_once CALENDAR_ROOT . 'Month.php'; |
|
57 | +require_once CALENDAR_ROOT.'Month.php'; |
|
58 | 58 | |
59 | 59 | /** |
60 | 60 | * Represents a Month and builds Days in tabular form<br> |
@@ -129,7 +129,7 @@ discard block |
||
129 | 129 | */ |
130 | 130 | public function build($sDates = []) |
131 | 131 | { |
132 | - require_once CALENDAR_ROOT . 'Table/Helper.php'; |
|
132 | + require_once CALENDAR_ROOT.'Table/Helper.php'; |
|
133 | 133 | $this->tableHelper = new Calendar_Table_Helper($this, $this->firstDay); |
134 | 134 | Calendar_Month::build($sDates); |
135 | 135 | $this->buildEmptyDaysBefore(); |
@@ -50,7 +50,7 @@ discard block |
||
50 | 50 | /** |
51 | 51 | * Load Calendar base class. |
52 | 52 | */ |
53 | -require_once CALENDAR_ROOT . 'Calendar.php'; |
|
53 | +require_once CALENDAR_ROOT.'Calendar.php'; |
|
54 | 54 | |
55 | 55 | /** |
56 | 56 | * Represents a Week and builds Days in tabular format<br> |
@@ -138,7 +138,7 @@ discard block |
||
138 | 138 | */ |
139 | 139 | public function __construct($y, $m, $d, $firstDay = null) |
140 | 140 | { |
141 | - require_once CALENDAR_ROOT . 'Table/Helper.php'; |
|
141 | + require_once CALENDAR_ROOT.'Table/Helper.php'; |
|
142 | 142 | parent::__construct($y, $m, $d); |
143 | 143 | $this->firstDay = $this->defineFirstDayOfWeek($firstDay); |
144 | 144 | $this->tableHelper = new Calendar_Table_Helper($this, $this->firstDay); |
@@ -170,7 +170,7 @@ discard block |
||
170 | 170 | */ |
171 | 171 | public function build($sDates = []) |
172 | 172 | { |
173 | - require_once CALENDAR_ROOT . 'Day.php'; |
|
173 | + require_once CALENDAR_ROOT.'Day.php'; |
|
174 | 174 | $year = $this->cE->stampToYear($this->thisWeek); |
175 | 175 | $month = $this->cE->stampToMonth($this->thisWeek); |
176 | 176 | $day = $this->cE->stampToDay($this->thisWeek); |
@@ -294,7 +294,7 @@ discard block |
||
294 | 294 | case 'array': |
295 | 295 | return $this->toArray($this->prevWeek); |
296 | 296 | case 'object': |
297 | - require_once CALENDAR_ROOT . 'Factory.php'; |
|
297 | + require_once CALENDAR_ROOT.'Factory.php'; |
|
298 | 298 | |
299 | 299 | return Calendar_Factory::createByTimestamp('Week', $this->prevWeek); |
300 | 300 | case 'timestamp': |
@@ -328,7 +328,7 @@ discard block |
||
328 | 328 | case 'array': |
329 | 329 | return $this->toArray($this->thisWeek); |
330 | 330 | case 'object': |
331 | - require_once CALENDAR_ROOT . 'Factory.php'; |
|
331 | + require_once CALENDAR_ROOT.'Factory.php'; |
|
332 | 332 | |
333 | 333 | return Calendar_Factory::createByTimestamp('Week', $this->thisWeek); |
334 | 334 | case 'timestamp': |
@@ -355,7 +355,7 @@ discard block |
||
355 | 355 | case 'array': |
356 | 356 | return $this->toArray($this->nextWeek); |
357 | 357 | case 'object': |
358 | - require_once CALENDAR_ROOT . 'Factory.php'; |
|
358 | + require_once CALENDAR_ROOT.'Factory.php'; |
|
359 | 359 | |
360 | 360 | return Calendar_Factory::createByTimestamp('Week', $this->nextWeek); |
361 | 361 | case 'timestamp': |
@@ -49,7 +49,7 @@ discard block |
||
49 | 49 | /** |
50 | 50 | * Load Calendar base class. |
51 | 51 | */ |
52 | -require_once CALENDAR_ROOT . 'Calendar.php'; |
|
52 | +require_once CALENDAR_ROOT.'Calendar.php'; |
|
53 | 53 | |
54 | 54 | /** |
55 | 55 | * Represents a Year and builds Months<br> |
@@ -103,7 +103,7 @@ discard block |
||
103 | 103 | */ |
104 | 104 | public function build($sDates = [], $firstDay = null) |
105 | 105 | { |
106 | - require_once CALENDAR_ROOT . 'Factory.php'; |
|
106 | + require_once CALENDAR_ROOT.'Factory.php'; |
|
107 | 107 | $this->firstDay = $this->defineFirstDayOfWeek($firstDay); |
108 | 108 | $monthsInYear = $this->cE->getMonthsInYear($this->thisYear()); |
109 | 109 | for ($i = 1; $i <= $monthsInYear; ++$i) { |
@@ -49,7 +49,7 @@ discard block |
||
49 | 49 | /** |
50 | 50 | * Load Calendar base class. |
51 | 51 | */ |
52 | -require_once CALENDAR_ROOT . 'Calendar.php'; |
|
52 | +require_once CALENDAR_ROOT.'Calendar.php'; |
|
53 | 53 | |
54 | 54 | /** |
55 | 55 | * Represents a Month and builds Days |
@@ -95,7 +95,7 @@ discard block |
||
95 | 95 | */ |
96 | 96 | public function build($sDates = []) |
97 | 97 | { |
98 | - require_once CALENDAR_ROOT . 'Day.php'; |
|
98 | + require_once CALENDAR_ROOT.'Day.php'; |
|
99 | 99 | $daysInMonth = $this->cE->getDaysInMonth($this->year, $this->month); |
100 | 100 | for ($i = 1; $i <= $daysInMonth; ++$i) { |
101 | 101 | $this->children[$i] = new Calendar_Day($this->year, $this->month, $i); |
@@ -49,7 +49,7 @@ discard block |
||
49 | 49 | /** |
50 | 50 | * Load Calendar base class. |
51 | 51 | */ |
52 | -require_once CALENDAR_ROOT . 'Calendar.php'; |
|
52 | +require_once CALENDAR_ROOT.'Calendar.php'; |
|
53 | 53 | |
54 | 54 | /** |
55 | 55 | * Represents a Minute and builds Seconds |
@@ -95,7 +95,7 @@ discard block |
||
95 | 95 | */ |
96 | 96 | public function build($sDates = []) |
97 | 97 | { |
98 | - require_once CALENDAR_ROOT . 'Second.php'; |
|
98 | + require_once CALENDAR_ROOT.'Second.php'; |
|
99 | 99 | $sIM = $this->cE->getSecondsInMinute($this->year, $this->month, $this->day, $this->hour, $this->minute); |
100 | 100 | for ($i = 0; $i < $sIM; ++$i) { |
101 | 101 | $this->children[$i] = new Calendar_Second($this->year, $this->month, $this->day, $this->hour, $this->minute, $i); |
@@ -121,7 +121,7 @@ discard block |
||
121 | 121 | && $this->day == $sDate->thisDay() |
122 | 122 | && $this->hour == $sDate->thisHour() |
123 | 123 | && $this->minute == $sDate->thisMinute()) { |
124 | - $key = (int)$sDate->thisSecond(); |
|
124 | + $key = (int) $sDate->thisSecond(); |
|
125 | 125 | if (isset($this->children[$key])) { |
126 | 126 | $sDate->setSelected(); |
127 | 127 | $this->children[$key] = $sDate; |
@@ -1,8 +1,8 @@ |
||
1 | 1 | <?php |
2 | 2 | // |
3 | 3 | |
4 | -require_once __DIR__ . '/simple_include.php'; |
|
5 | -require_once __DIR__ . '/calendar_include.php'; |
|
4 | +require_once __DIR__.'/simple_include.php'; |
|
5 | +require_once __DIR__.'/calendar_include.php'; |
|
6 | 6 | |
7 | 7 | Mock::generate('Calendar_Engine_Interface', 'Mock_Calendar_Engine'); |
8 | 8 | Mock::generate('Calendar_Second', 'Mock_Calendar_Second'); |
@@ -27,13 +27,13 @@ |
||
27 | 27 | public function testPrevDay_Array() |
28 | 28 | { |
29 | 29 | $this->assertEqual([ |
30 | - 'year' => 2003, |
|
31 | - 'month' => 10, |
|
32 | - 'day' => 24, |
|
33 | - 'hour' => 0, |
|
34 | - 'minute' => 0, |
|
35 | - 'second' => 0, |
|
36 | - ], $this->cal->prevDay('array')); |
|
30 | + 'year' => 2003, |
|
31 | + 'month' => 10, |
|
32 | + 'day' => 24, |
|
33 | + 'hour' => 0, |
|
34 | + 'minute' => 0, |
|
35 | + 'second' => 0, |
|
36 | + ], $this->cal->prevDay('array')); |
|
37 | 37 | } |
38 | 38 | |
39 | 39 | public function testPrevSecond() |
@@ -1,10 +1,10 @@ discard block |
||
1 | 1 | <?php |
2 | 2 | // |
3 | 3 | |
4 | -require_once __DIR__ . '/simple_include.php'; |
|
5 | -require_once __DIR__ . '/calendar_include.php'; |
|
4 | +require_once __DIR__.'/simple_include.php'; |
|
5 | +require_once __DIR__.'/calendar_include.php'; |
|
6 | 6 | |
7 | -require_once __DIR__ . '/./calendar_test.php'; |
|
7 | +require_once __DIR__.'/./calendar_test.php'; |
|
8 | 8 | |
9 | 9 | /** |
10 | 10 | * Class TestOfMinute. |
@@ -111,7 +111,7 @@ discard block |
||
111 | 111 | |
112 | 112 | public function testSelection() |
113 | 113 | { |
114 | - require_once CALENDAR_ROOT . 'Second.php'; |
|
114 | + require_once CALENDAR_ROOT.'Second.php'; |
|
115 | 115 | $selection = [new Calendar_Second(2003, 10, 25, 13, 32, 43)]; |
116 | 116 | $this->cal->build($selection); |
117 | 117 | $i = 0; |