Merge branch 'patch-1'
* patch-1: nested_inheritance_interface testcase enhancement Add nested_inheritance_interface test for csharp Fix class name for nested classes Add nested_inheritance_interface test Fix class name for nested classes Conflicts: CHANGES.current
This commit is contained in:
commit
aea7a6d30f
7 changed files with 90 additions and 2 deletions
|
|
@ -0,0 +1,32 @@
|
|||
import nested_inheritance_interface.*;
|
||||
import java.util.Arrays;
|
||||
|
||||
public class nested_inheritance_interface_runme {
|
||||
|
||||
static {
|
||||
try {
|
||||
System.loadLibrary("nested_inheritance_interface");
|
||||
} catch (UnsatisfiedLinkError e) {
|
||||
System.err.println("Native code library failed to load. See the chapter on Dynamic Linking Problems in the SWIG Java documentation for help.\n" + e);
|
||||
System.exit(1);
|
||||
}
|
||||
}
|
||||
|
||||
private static void takeIA(IASwigInterface ia) {
|
||||
}
|
||||
|
||||
public static void main(String argv[]) {
|
||||
Class[] BNInterfaces = B.N.class.getInterfaces();
|
||||
String expectedInterfacesString = "[interface nested_inheritance_interface.IASwigInterface]";
|
||||
String actualInterfacesString = Arrays.toString(BNInterfaces);
|
||||
if (!expectedInterfacesString.equals(actualInterfacesString))
|
||||
throw new RuntimeException("Expected interfaces for " + B.N.class.getName() + ": \n" + expectedInterfacesString + "\n" + "Actual interfaces: \n" + actualInterfacesString);
|
||||
|
||||
if (!IASwigInterface.class.isInterface())
|
||||
throw new RuntimeException(IASwigInterface.class.getName() + " should be an interface but is not");
|
||||
|
||||
// overloaded methods check
|
||||
B.N d = new B.N();
|
||||
takeIA(d);
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue