  @Test
  public void questionsToSubjectsDto() throws Exception {

    Question q1 = new Question().id(1L).label("question1").subject(new Subject().id(1L));
    Question q2 = new Question().id(2L).label("question2").subject(new Subject().id(1L));
    Question q3 = new Question().id(3L).label("question3").subject(new Subject().id(2L));

    List<SubjectDto> subjects = subjectMapper.questionsToSubjectsDto(Arrays.asList(q1, q2, q3));

    Assert.assertNotNull(subjects);
    Assert.assertEquals(subjects.size(), 2);
    subjects.forEach((this::assertSubjectDtoAndItsQuestionsNotNull));
  }