use of org.gradle.api.tasks.TaskCollection in project core-java by SpineEventEngine.
the class ModelVerifierShould method setUp.
@Before
public void setUp() {
project = mock(Project.class);
when(project.getSubprojects()).thenReturn(Collections.<Project>emptySet());
when(project.getRootProject()).thenReturn(project);
final TaskContainer tasks = mock(TaskContainer.class);
final TaskCollection emptyTaskCollection = mock(TaskCollection.class);
when(emptyTaskCollection.iterator()).thenReturn(Iterators.emptyIterator());
when(emptyTaskCollection.toArray()).thenReturn(EMPTY_ARRAY);
when(tasks.withType(any(Class.class))).thenReturn(emptyTaskCollection);
when(project.getTasks()).thenReturn(tasks);
}
Aggregations