Skip to content

Commit c06c7e4

Browse files
Test for abstract class with two generic arguments
1 parent e936a29 commit c06c7e4

8 files changed

+34
-0
lines changed
466 Bytes
Binary file not shown.
240 Bytes
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
645 Bytes
Binary file not shown.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
interface AbstractInt<K,V> { V get(); }
2+
3+
class AbstractImpl<K,V> implements AbstractInt<K,V> {
4+
V t;
5+
public V get() { return t; }
6+
}
7+
8+
public class AbstractTest
9+
{
10+
class Dummy { private boolean b; }
11+
class ClassA { private int id; }
12+
class ClassB {
13+
private int id;
14+
int getId() { return id; }
15+
}
16+
17+
public int getFromAbstract(AbstractInt<ClassA, ClassB> arg) {
18+
AbstractImpl<Dummy, Dummy> dummy = new AbstractImpl<>();
19+
ClassB b = arg.get();
20+
int i = b.getId();
21+
return i;
22+
}
23+
}
+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
CORE
2+
AbstractTest.class
3+
--cover location --function AbstractTest.getFromAbstract
4+
^EXIT=0$
5+
^SIGNAL=0$
6+
file AbstractTest.java line 18 .* SATISFIED
7+
file AbstractTest.java line 19 .* SATISFIED
8+
file AbstractTest.java line 20 .* SATISFIED
9+
file AbstractTest.java line 21 .* SATISFIED
10+
11+

0 commit comments

Comments
 (0)