Skip to content

Commit

Permalink
fix CallHierarchyTestHelper generics
Browse files Browse the repository at this point in the history
  • Loading branch information
EcljpseB0T authored and jukzi committed Jan 19, 2024
1 parent d10ed73 commit d367f3d
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -579,10 +579,10 @@ protected void assertNoErrorMarkers(IResource resource) throws Exception {
/**
* Asserts that all the expected methods were found in the call results.
*/
public void assertCalls(Collection<IMember> expectedMembers, Collection<?> calls) {
public void assertCalls(Collection<IMember> expectedMembers, Collection<MethodWrapper> calls) {
Collection<IMember> foundMembers= new ArrayList<>();

for (MethodWrapper element : (Collection<MethodWrapper>)calls) {
for (MethodWrapper element : calls) {
foundMembers.add(element.getMember());
}

Expand All @@ -601,7 +601,7 @@ public void assertCalls(Collection<IMember> expectedMembers, MethodWrapper[] cal
* Asserts that all the expected methods were found in the call results.
*/
public void assertCalls(IMember[] expectedMembers, Object[] callResults) {
assertCalls(Arrays.asList(expectedMembers), Arrays.asList(callResults));
assertCalls(Arrays.asList(expectedMembers), Arrays.stream(callResults).map(MethodWrapper.class::cast).toList());
}

public MethodWrapper findMethodWrapper(IMethod method, Object[] methodWrappers) {
Expand Down

0 comments on commit d367f3d

Please sign in to comment.