public List<Questionary> getAllQuestionaries() {
List<Questionary> questionaries = new ArrayList<>();
for (int i = 0; i < 5; i++) {
List<Question> questions = new ArrayList<>();
for (int j = 0; j < 5; j++) {
Question q = new Question();
q.setText("Test question " + i + " - " + j);
List<Answer> answers = new ArrayList<>();
Answer a1 = new Answer();
a1.setCorrect(true);
a1.setText("Correct answer");
Answer a2 = new Answer();
a2.setCorrect(false);
a2.setText("Incorrect answer");
answers.add(a1);
answers.add(a2);
q.setAnswers(answers);
questions.add(q);
}
Questionary questionary = new Questionary();
questionary.setDescription("Description for Test questionary " + i);
questionary.setName("Test questionary " + i);