Drop the image description field
CI / Deploy / PHP 8.4 (push) Successful in 1m36s
CI / Deploy / PHP 8.5 (push) Successful in 1m36s
CI / Deploy / test (push) Successful in 1s
CI / Deploy / deploy (push) Skipped

Slide images are shown on the presenter's screen, so a description for
screen readers is not asked for any more. The column stays (always empty).

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
gnilebeinandClaude Sonnet 5.5 committed 2026-11-21 13:35:48 +01:00
1 parent ebaf6fbe53
commit 7a80794ded
12 files changed
+110 -35

No files matched your search

@@ -127,6 +127,37 @@ class VoteServiceTest extends TestCase
$service->editText($poll, $slide, 'p1', ['comment' => '']);
}
public function testChoiceCommentOnlyIsNotCountedAsVote(): void
{
[$poll] = $this->createPoll();
$slide = $this->createSlide($poll, Slide::TYPE_CHOICE, ['settings' => ['comments' => true, 'comment_only' => true]], ['A', 'B']);
$poll = $this->goLive($poll, $slide);
$service = new VoteService();
$service->submit($poll, $slide, 'p1', ['option_id' => $slide->slide_options[0]->id]);
$service->submit($poll, $slide, 'p2', ['comment' => 'Keine passt']);
$results = (new ResultsService())->forSlide($slide);
$this->assertSame(2, $results['participants']);
$this->assertSame(1, $results['votes']);
$this->assertSame(1, $results['commentOnly']);
$this->assertEquals([100, 0], array_column($results['options'], 'percent'));
$this->assertSame(['Keine passt'], array_column($results['comments'], 'text'));
$service->editText($poll, $slide, 'p2', ['comment' => 'Keine passt wirklich']);
$this->expectExceptionMessage('nicht leer sein');
$service->editText($poll, $slide, 'p2', ['comment' => '']);
}
public function testChoiceWithoutSelectionNeedsCommentOnlySetting(): void
{
[$poll] = $this->createPoll();
$slide = $this->createSlide($poll, Slide::TYPE_CHOICE, ['settings' => ['comments' => true]], ['A', 'B']);
$poll = $this->goLive($poll, $slide);
$this->expectExceptionMessage('Bitte wähle eine Antwort aus.');
(new VoteService())->submit($poll, $slide, 'p1', ['comment' => 'Nur Kommentar']);
}
public function testMultipleChoiceResults(): void
{
[$poll] = $this->createPoll();