添加网站文件
This commit is contained in:
22
vendor/songshenzong/support/tests/TimeTest.php
vendored
Normal file
22
vendor/songshenzong/support/tests/TimeTest.php
vendored
Normal file
@@ -0,0 +1,22 @@
|
||||
<?php
|
||||
|
||||
namespace Songshenzong\Support\Test\Core;
|
||||
|
||||
use Songshenzong\Support\Time;
|
||||
use PHPUnit\Framework\TestCase;
|
||||
|
||||
class TimeTest extends TestCase
|
||||
{
|
||||
public function testDates()
|
||||
{
|
||||
$expect = [
|
||||
'2019-09-10',
|
||||
'2019-09-11',
|
||||
'2019-09-12',
|
||||
];
|
||||
|
||||
self::assertEquals($expect, Time::dates('2019-09-10', '2019-09-12'));
|
||||
|
||||
self::assertEquals($expect, Time::dates(strtotime('2019-09-10'), strtotime('2019-09-12')));
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user