diff --git a/tests/SortableTest.php b/tests/SortableTest.php index b77ae93..4b7248a 100644 --- a/tests/SortableTest.php +++ b/tests/SortableTest.php @@ -46,11 +46,11 @@ public function it_can_set_a_new_order() public function it_can_touch_timestamps_when_setting_a_new_order() { $this->setUpTimestamps(); - DummyWithTimestamps::query()->update(['updated_at' => now()]); + DummyWithTimestamps::query()->update(['updated_at' => now()]); $originalTimestamps = DummyWithTimestamps::all()->pluck('updated_at'); - + $this->travelTo(now()->addMinute()); - + config()->set('eloquent-sortable.ignore_timestamps', false); $newOrder = Collection::make(DummyWithTimestamps::all()->pluck('id'))->shuffle()->toArray(); DummyWithTimestamps::setNewOrder($newOrder); @@ -64,11 +64,11 @@ public function it_can_touch_timestamps_when_setting_a_new_order() public function it_can_set_a_new_order_without_touching_timestamps() { $this->setUpTimestamps(); - DummyWithTimestamps::query()->update(['updated_at' => now()]); + DummyWithTimestamps::query()->update(['updated_at' => now()]); $originalTimestamps = DummyWithTimestamps::all()->pluck('updated_at'); - + $this->travelTo(now()->addMinute()); - + config()->set('eloquent-sortable.ignore_timestamps', true); $newOrder = Collection::make(DummyWithTimestamps::all()->pluck('id'))->shuffle()->toArray(); DummyWithTimestamps::setNewOrder($newOrder);