diff options
author | Andy Clement <andrew.clement@gmail.com> | 2013-01-23 13:25:49 -0800 |
---|---|---|
committer | Andy Clement <andrew.clement@gmail.com> | 2013-01-23 13:25:49 -0800 |
commit | 8dc8d1e0b897d9ab515ed3d99abaee930b45c9d5 (patch) | |
tree | 3ba6d9b0089e76904f2048d82a24770ac87c4c2c /testing | |
parent | 83df4c5194b159f6113aade3e73549d59972fd4a (diff) | |
download | aspectj-8dc8d1e0b897d9ab515ed3d99abaee930b45c9d5.tar.gz aspectj-8dc8d1e0b897d9ab515ed3d99abaee930b45c9d5.zip |
more changes to make if point cut generated names stable
Diffstat (limited to 'testing')
-rw-r--r-- | testing/newsrc/org/aspectj/testing/XMLBasedAjcTestCase.java | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/testing/newsrc/org/aspectj/testing/XMLBasedAjcTestCase.java b/testing/newsrc/org/aspectj/testing/XMLBasedAjcTestCase.java index 9ecd5d885..29ada2727 100644 --- a/testing/newsrc/org/aspectj/testing/XMLBasedAjcTestCase.java +++ b/testing/newsrc/org/aspectj/testing/XMLBasedAjcTestCase.java @@ -319,12 +319,19 @@ public abstract class XMLBasedAjcTestCase extends AjcTestCase { } protected Method getMethodStartsWith(JavaClass jc, String prefix) { + return getMethodStartsWith(jc,prefix,1); + } + + protected Method getMethodStartsWith(JavaClass jc, String prefix, int whichone) { Method[] meths = jc.getMethods(); for (int i = 0; i < meths.length; i++) { Method method = meths[i]; System.out.println(method); if (method.getName().startsWith(prefix)) { - return method; + whichone--; + if (whichone==0) { + return method; + } } } return null; |