diff --git a/tests/ExampleTest.php b/tests/ExampleTest.php index 55f68baa..6f072b63 100644 --- a/tests/ExampleTest.php +++ b/tests/ExampleTest.php @@ -1,11 +1,22 @@ '福建车媒通网络科技有限公司', + 'month' => '2016-01' +]; -$export = new CompanyReportExport($conditions); -$url = ExportService::store($export, $this->disk); +$start = Carbon::parse('2016-01')->startOfMonth(); +$end = Carbon::parse('2019-07')->endOfMonth(); + +for ($i = 0; $i <= $end->diffInMonths($start); $i++) { + $month = $start->copy()->addMonths($i)->format('Y-m'); + $conditions['month'] = $month; + $export = new CompanyReportExport($conditions); + $url = ExportService::store($export, $this->disk); +}