12345678910111213141516171819202122232425262728293031323334 |
- <?php
- use PHPUnit\Framework\TestCase;
- define('APP_ID', 'refill_stat');
- define('BASE_ROOT_PATH', str_replace('/test', '', dirname(__FILE__)));
- require_once(BASE_ROOT_PATH . '/global.php');
- require_once(BASE_CORE_PATH . '/lrlz.php');
- require_once(BASE_ROOT_PATH . '/fooder.php');
- require_once (BASE_ROOT_PATH . '/helper/statistics/stat_refill.php');
- class TestRefillCommand extends TestCase
- {
- public static function setUpBeforeClass(): void
- {
- Base::run_util();
- }
- //docker-compose run -d phpcli php /var/www/html/phpunit-9.2.5.phar --filter "/(TestRefillCommand::testRefillStat)( .*)?$/" --test-suffix TestRefillCommand.php /var/www/html/test
- public function testRefillStat()
- {
- $dates = [
- '2022-01-10',
- '2022-01-11',
- '2022-01-12',
- '2022-01-14',
- '2022-01-15'
- ];
- $refill = new statistics\stat_refill();
- $refill->restat($dates);
- }
- }
|