Skip to content

Commit adbf41a

Browse files
authored
Add ViewComponentColumn label test (rappasoft#2075)
1 parent 59a7967 commit adbf41a

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

tests/Unit/Views/Columns/ViewComponentColumnTest.php

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,4 +77,11 @@ public function test_can_use_custom_component(): void
7777
$this->assertSame('<div>2420</div>', $contents);
7878
7979
}*/
80+
81+
public function test_can_not_user_as_label(): void
82+
{
83+
$this->expectException(DataTableConfigurationException::class);
84+
85+
$column = ViewComponentColumn::make('Total Users')->label(fn () => 'My Label')->getContents(Pet::find(1));
86+
}
8087
}

0 commit comments

Comments
 (0)