@Test
public void should_return_list_of_module_needed_by_widgets() throws Exception {

    Component component = mockComponentFor(aWidget().modules("aModule", "anotherModule"));
    Set<String> modules = requiredModulesVisitor.visit(component);
    assertThat(modules).containsOnly("aModule", "anotherModule");
}