@Test
public void testFindAllSubEventsInHierarchy() throws Exception {

	TeamAppsDtoModel model = createModel("interface I { subevent i(int i); }"
			+ "interface I2 { subevent i2(int i2); }"
			+ "class M implements I { subevent m(int m); }"
			+ "class N extends M implements I2 { subevent n(int n); }"
			+ "class A { event x(String x1, subevent<M> x2); }");
	List<TeamAppsDtoParser.SubEventDeclarationContext> result = model.findAllSubEventsInHierarchy(model.findClassByName("M", false));
	Assertions.assertThat(result).extracting(subEventDeclarationContext -> subEventDeclarationContext.Identifier().getText())
			.containsExactlyInAnyOrder("i", "i2", "m", "n");
}