File tree Expand file tree Collapse file tree 3 files changed +8
-8
lines changed
Expand file tree Collapse file tree 3 files changed +8
-8
lines changed Original file line number Diff line number Diff line change 1010use Illuminate \Http \Request ;
1111use Illuminate \Http \Resources \Json \AnonymousResourceCollection ;
1212
13- class QuestionsGetController extends Controller
13+ class QuestionsIndexController extends Controller
1414{
1515 protected Question $ question ;
1616
Original file line number Diff line number Diff line change 1010use Laravel \Lumen \Testing \DatabaseMigrations ;
1111use Tests \TestCase ;
1212
13- class QuestionsGetTest extends TestCase
13+ class QuestionsIndexTest extends TestCase
1414{
1515 use DatabaseMigrations;
1616
@@ -28,7 +28,7 @@ protected function setUp(): void
2828 public function it_list_non_deleted_question (): void
2929 {
3030 $ deleteQuestion = QuestionFactory::new ([
31- 'deleted_at ' => Carbon::now ()-> toDateString () ,
31+ 'deleted_at ' => Carbon::now (),
3232 ])
3333 ->create ();
3434
@@ -138,11 +138,11 @@ public function it_search_by_title(): void
138138 public function it_search_by_created_date (): void
139139 {
140140 QuestionFactory::new ([
141- 'created_at ' => Carbon::now ()->subYears (2 )-> toDateString () ,
141+ 'created_at ' => Carbon::now ()->subYears (2 ),
142142 ])
143143 ->create ();
144144 QuestionFactory::new ([
145- 'created_at ' => Carbon::now ()->subYears (3 )-> toDateString () ,
145+ 'created_at ' => Carbon::now ()->subYears (3 ),
146146 ])
147147 ->create ();
148148
@@ -167,7 +167,7 @@ public function it_search_by_created_date(): void
167167 public function it_search_by_resolved (): void
168168 {
169169 QuestionFactory::new ([
170- 'resolved_at ' => Carbon::now ()-> toDateString () ,
170+ 'resolved_at ' => Carbon::now (),
171171 ])
172172 ->count (5 )
173173 ->create ();
Original file line number Diff line number Diff line change 11<?php
22
33use Domains \Discussions \Controllers \AnswersStoreController ;
4- use Domains \Discussions \Controllers \QuestionsGetController ;
4+ use Domains \Discussions \Controllers \QuestionsIndexController ;
55use Domains \Discussions \Controllers \QuestionsStoreController ;
66use Domains \Discussions \Controllers \QuestionsUpdateController ;
77use Domains \Discussions \Controllers \QuestionsViewController ;
2626
2727Route::get ('questions ' , [
2828 'as ' => 'questions.index ' ,
29- 'uses ' => QuestionsGetController ::class
29+ 'uses ' => QuestionsIndexController ::class
3030]);
3131
3232Route::get ('questions/{questionId} ' , [
You can’t perform that action at this time.
0 commit comments