From 36fb09f3a6287d23b6c373cbcbf100806613c2b4 Mon Sep 17 00:00:00 2001 From: Igor Kravchenko Date: Mon, 30 Sep 2024 18:49:57 +0300 Subject: [PATCH] Add accessibility identifiers to 'submit' and 'cancel' survey buttons In order to ensure in acceptance tests that survey gets shown when engagement ended by operator in background, survey_cancel_button and survey_submit_button accessibility identifiers must be assigned to relevant buttons. MOB-3612 --- .../ViewController/Survey/SurveyViewController.View.swift | 2 ++ 1 file changed, 2 insertions(+) diff --git a/GliaWidgets/Sources/ViewController/Survey/SurveyViewController.View.swift b/GliaWidgets/Sources/ViewController/Survey/SurveyViewController.View.swift index 564324620..13be11995 100644 --- a/GliaWidgets/Sources/ViewController/Survey/SurveyViewController.View.swift +++ b/GliaWidgets/Sources/ViewController/Survey/SurveyViewController.View.swift @@ -35,11 +35,13 @@ extension Survey { // from getting truncated, for example for large // dynamic font types. $0.titleLabel?.lineBreakMode = .byWordWrapping + $0.accessibilityIdentifier = "survey_cancel_button" } let submitButton = UIButton(type: .custom).make { $0.setTitle(Localization.General.submit, for: .normal) $0.titleLabel?.numberOfLines = 0 $0.titleLabel?.lineBreakMode = .byWordWrapping + $0.accessibilityIdentifier = "survey_submit_button" } lazy var buttonStackView = UIStackView.make(.horizontal, spacing: 16)( cancelButton,