@Test public void testRemoveQuestion() { QuestionForm questionForm = new QuestionForm(); ArrayList<Question> questions = new ArrayList<Question>(); questionForm.setQuestions(questions); String title = "title"; questions.add(getQuestion("1", title, "freeText")); questionController.removeQuestion(questionForm, ""); questionController.removeQuestion(questionForm, "junk"); Assert.assertThat(questionForm.getQuestions().size(), is(1)); questionController.removeQuestion(questionForm, title); Assert.assertThat(questionForm.getQuestions().size(), is(0)); }
public void removeQuestion(QuestionForm questionForm, String questionTitle) { questionForm.removeQuestion(questionTitle); }
QuestionController extends QuestionnaireController { public void removeQuestion(QuestionForm questionForm, String questionTitle) { questionForm.removeQuestion(questionTitle); } }
QuestionController extends QuestionnaireController { public void removeQuestion(QuestionForm questionForm, String questionTitle) { questionForm.removeQuestion(questionTitle); } @SuppressWarnings({"UnusedDeclaration"})  QuestionController();  QuestionController(QuestionnaireServiceFacade questionnaireServiceFacade); }
QuestionController extends QuestionnaireController { public void removeQuestion(QuestionForm questionForm, String questionTitle) { questionForm.removeQuestion(questionTitle); } @SuppressWarnings({"UnusedDeclaration"})  QuestionController();  QuestionController(QuestionnaireServiceFacade questionnaireServiceFacade); @RequestMapping("/viewQuestions.ftl") String getAllQuestions(ModelMap model); String addQuestion(QuestionForm questionForm, RequestContext requestContext, boolean createMode); String addSmartChoiceTag(QuestionForm questionForm, RequestContext requestContext, int choiceIndex); void removeQuestion(QuestionForm questionForm, String questionTitle); String createQuestions(QuestionForm questionForm, RequestContext requestContext); }
QuestionController extends QuestionnaireController { public void removeQuestion(QuestionForm questionForm, String questionTitle) { questionForm.removeQuestion(questionTitle); } @SuppressWarnings({"UnusedDeclaration"})  QuestionController();  QuestionController(QuestionnaireServiceFacade questionnaireServiceFacade); @RequestMapping("/viewQuestions.ftl") String getAllQuestions(ModelMap model); String addQuestion(QuestionForm questionForm, RequestContext requestContext, boolean createMode); String addSmartChoiceTag(QuestionForm questionForm, RequestContext requestContext, int choiceIndex); void removeQuestion(QuestionForm questionForm, String questionTitle); String createQuestions(QuestionForm questionForm, RequestContext requestContext);  }