diff --git a/tests/SortableTest.php b/tests/SortableTest.php index 9f30181..40cf7a8 100644 --- a/tests/SortableTest.php +++ b/tests/SortableTest.php @@ -430,29 +430,26 @@ public function it_can_tell_if_element_is_last_in_order() public function it_can_determine_custom_column_and_get_order_number() { $model = Dummy::first(); - $this->assertEquals($model->getOrder(), 1); + + $model = new class () extends Dummy { public $sortable = [ 'order_column_name' => 'my_custom_order_column', ]; }; - - $this->assertEquals($model->determineOrderColumnName(), 'my_custom_order_column'); - $model->my_custom_order_column = 2; - $this->assertEquals($model->getOrder(), 2); + + $model = new class () extends Dummy { public $sortable = [ 'order_column_name' => 'my_other_custom_order_column', ]; }; - $model->my_other_custom_order_column = 3; - $this->assertEquals($model->getOrder(), 3); } }