We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 74961b2 commit 640ee9eCopy full SHA for 640ee9e
routes/console.php
@@ -19,3 +19,9 @@
19
20
\Illuminate\Support\Facades\Schedule::command('app:check_email')
21
->everyMinute();
22
+
23
24
25
+\Illuminate\Support\Facades\Schedule::call(function () {
26
+ (new \App\Domains\Projects\DailyReportService())->handle();
27
+})->dailyAt('05:00');
tests/Feature/Models/ProjectTest.php
@@ -24,4 +24,14 @@ public function test_model(): void
$this->assertNotNull($model->team->id);
$this->assertNotNull($model->tasks->first()->id);
}
28
+ public function test_active() {
29
+ $model = Project::factory()->create([
30
+ 'start_date' => now()->subDays(5),
31
+ 'end_date' => now()->subDays(2),
32
+ ]);
33
34
+ $this->assertEmpty(Project::active()->get());
35
+ }
36
37
0 commit comments