### Eclipse Workspace Patch 1.0 #P org.eclipse.jdt.core.tests.model Index: src/org/eclipse/jdt/core/tests/dom/ASTModelBridgeTests.java =================================================================== RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.model/src/org/eclipse/jdt/core/tests/dom/ASTModelBridgeTests.java,v retrieving revision 1.46 diff -u -r1.46 ASTModelBridgeTests.java --- src/org/eclipse/jdt/core/tests/dom/ASTModelBridgeTests.java 6 Oct 2006 16:45:15 -0000 1.46 +++ src/org/eclipse/jdt/core/tests/dom/ASTModelBridgeTests.java 14 Nov 2006 16:14:07 -0000 @@ -42,7 +42,7 @@ // All specified tests which do not belong to the class are skipped... static { // TESTS_PREFIX = "testBug86380"; -// TESTS_NAMES = new String[] { "testBinaryMemberTypeConstructor" }; +// TESTS_NAMES = new String[] { "testCreateBindings19" }; // TESTS_NUMBERS = new int[] { 83230 }; // TESTS_RANGE = new int[] { 83304, -1 }; } @@ -1437,5 +1437,23 @@ ); } - + /* + * https://bugs.eclipse.org/bugs/show_bug.cgi?id=160637 + */ + public void testCreateBindings19() throws CoreException { + IBinding[] bindings = createBinaryBindings( + "public class A {\n" + + " String foo(String s) {\n" + + " return null;\n" + + " }\n" + + "}", + getClassFile("/P/lib/A.class").getType().getMethod("foo", new String[] {"Ljava.lang.String;"}) + ); + assertNotNull("No bindings", bindings); + assertEquals("Wrong size", 1, bindings.length); + assertTrue("Not a method binding", bindings[0] instanceof IMethodBinding); + assertBindingsEqual( + "LA;.foo(Ljava/lang/String;)Ljava/lang/String;", + bindings); + } }