Source:
<code>private void testResponseRate() { feedbackEditPage.clickNewQuestionButton(); feedbackEditPage.selectNewQuestionTypeAndWaitForNewQuestionPanelReady("TEXT"); feedbackEditPage.fillQuestionTextBoxForNewQuestion("new question"); <START> feedbackEditPage.fillQuestionDescriptionForNewQuestion("more details"); <END> feedbackEditPage.clickAddQuestionButton(); FeedbackResponseAttributes feedbackResponse = new FeedbackResponseAttributes( feedbackSessionName, courseId, "1", FeedbackQuestionType.TEXT, "tmms.test@gmail.tmt", Const.DEFAULT_SECTION, "alice.b.tmms@gmail.tmt", Const.DEFAULT_SECTION, new Text("Response from instructor to Alice")); BackDoor.createFeedbackResponse(feedbackResponse); ______TS("check response rate before editing question"); InstructorFeedbackSessionsPage feedbacksPage = navigateToInstructorFeedbackSessionsPage(); feedbacksPage.waitForAjaxLoaderGifToDisappear(); feedbacksPage.clickViewResponseLink(courseId, feedbackSessionName); feedbacksPage.verifyResponseValue("1 / 1", courseId, feedbackSessionName); ______TS("check warning is displayed while editing visibility options of question with existing response"); feedbackEditPage = getFeedbackEditPage(); assertTrue(feedbackEditPage.isAlertClassEnabledForVisibilityOptions(1)); feedbackEditPage.clickEditQuestionButton(1); feedbackEditPage.enableOtherFeedbackPathOptions(1); feedbackEditPage.selectRecipientToBe(FeedbackParticipantType.TEAMS, 1); feedbackEditPage.clickSaveExistingQuestionButton(1); feedbackEditPage.waitForConfirmationModalAndClickOk(); ______TS("check no warning displayed while editing visibility options of question without responses"); assertFalse(feedbackEditPage.isAlertClassEnabledForVisibilityOptions(1)); ______TS("check response rate after editing question"); feedbacksPage = navigateToInstructorFeedbackSessionsPage(); feedbacksPage.waitForAjaxLoaderGifToDisappear(); feedbacksPage.clickViewResponseLink(courseId, feedbackSessionName); feedbacksPage.verifyResponseValue("0 / 1", courseId, feedbackSessionName); }</code><technical_language>this get deleted? code depends this function</technical_language>

Target:
private void testResponseRate() { feedbackEditPage.clickNewQuestionButton(); feedbackEditPage.selectNewQuestionTypeAndWaitForNewQuestionPanelReady("TEXT"); feedbackEditPage.fillQuestionTextBoxForNewQuestion("new question"); feedbackEditPage.fillQuestionDescriptionForNewQuestion("more details"); feedbackEditPage.clickAddQuestionButton(); FeedbackResponseAttributes feedbackResponse = new FeedbackResponseAttributes( feedbackSessionName, courseId, "1", FeedbackQuestionType.TEXT, "tmms.test@gmail.tmt", Const.DEFAULT_SECTION, "alice.b.tmms@gmail.tmt", Const.DEFAULT_SECTION, new Text("Response from instructor to Alice")); BackDoor.createFeedbackResponse(feedbackResponse); ______TS("check response rate before editing question"); InstructorFeedbackSessionsPage feedbacksPage = navigateToInstructorFeedbackSessionsPage(); feedbacksPage.waitForAjaxLoaderGifToDisappear(); feedbacksPage.clickViewResponseLink(courseId, feedbackSessionName); feedbacksPage.verifyResponseValue("1 / 1", courseId, feedbackSessionName); ______TS("check warning is displayed while editing visibility options of question with existing response"); feedbackEditPage = getFeedbackEditPage(); assertTrue(feedbackEditPage.isAlertClassEnabledForVisibilityOptions(1)); feedbackEditPage.clickEditQuestionButton(1); feedbackEditPage.enableOtherFeedbackPathOptions(1); feedbackEditPage.selectRecipientToBe(FeedbackParticipantType.TEAMS, 1); feedbackEditPage.clickSaveExistingQuestionButton(1); feedbackEditPage.waitForConfirmationModalAndClickOk(); ______TS("check no warning displayed while editing visibility options of question without responses"); assertFalse(feedbackEditPage.isAlertClassEnabledForVisibilityOptions(1)); ______TS("check response rate after editing question"); feedbacksPage = navigateToInstructorFeedbackSessionsPage(); feedbacksPage.waitForAjaxLoaderGifToDisappear(); feedbacksPage.clickViewResponseLink(courseId, feedbackSessionName); feedbacksPage.verifyResponseValue("0 / 1", courseId, feedbackSessionName); feedbackEditPage = getFeedbackEditPage(); feedbackEditPage.clickDeleteQuestionLink(1); feedbackEditPage.waitForConfirmationModalAndClickOk(); }