Skip to content

Commit

Permalink
Add label fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
lrljoe committed Dec 16, 2024
1 parent d235860 commit 1e5d809
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions tests/Unit/Views/ColumnTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,18 @@ public function test_cannot_collapse_on_tablet_and_mobile(): void
$contents = $column->renderContents($rows->first());
}

public function test_custom_sorting_pills_defaults_correctly(): void
{
$column = Column::make('Name', 'name');
$defaultString = __($this->basicTable->getLocalisationPath().'not_applicable');

$this->assertSame('A-Z', $column->getCustomSortingPillDirections('asc'));
$this->assertSame('Z-A', $column->getCustomSortingPillDirections('desc'));
$this->assertSame($defaultString, $column->getCustomSortingPillDirections('faulty_string'));

}


public function test_custom_sorting_pills_label_defaults_correctly(): void
{
$column = Column::make('Name', 'name');
Expand Down

0 comments on commit 1e5d809

Please sign in to comment.