summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authoraclement <aclement>2008-06-16 18:08:02 +0000
committeraclement <aclement>2008-06-16 18:08:02 +0000
commit1d7244faef6a04535408216624adc1d60e161ff8 (patch)
tree90f6780191b38b6de52282c1ca2d92fa13a1cf1e /tests
parentdad6ba44ca81c718ac5f62d71c5ee296080fce9b (diff)
downloadaspectj-1d7244faef6a04535408216624adc1d60e161ff8.tar.gz
aspectj-1d7244faef6a04535408216624adc1d60e161ff8.zip
update test to pass on Windows too !
Diffstat (limited to 'tests')
-rw-r--r--tests/src/org/aspectj/systemtest/ajc161/Ajc161Tests.java13
1 files changed, 6 insertions, 7 deletions
diff --git a/tests/src/org/aspectj/systemtest/ajc161/Ajc161Tests.java b/tests/src/org/aspectj/systemtest/ajc161/Ajc161Tests.java
index bac5760a4..3cb5e04a9 100644
--- a/tests/src/org/aspectj/systemtest/ajc161/Ajc161Tests.java
+++ b/tests/src/org/aspectj/systemtest/ajc161/Ajc161Tests.java
@@ -47,15 +47,14 @@ public class Ajc161Tests extends org.aspectj.testing.XMLBasedAjcTestCase {
runTest("incorrect call relationship");
IRelationshipMap irm = AsmManager.getDefault().getRelationshipMap();
Set entries = irm.getEntries();
- String gotit = "";
+ boolean gotSomethingValid = false;
+ String expected = "<recursivepackage{RecursiveCatcher.java}RecursiveCatcher~recursiveCall~I?method-call(void recursivepackage.RecursiveCatcher.recursiveCall(int))";
for (Iterator iterator = entries.iterator(); iterator.hasNext();) {
- Object object = (Object) iterator.next();
- gotit = (String) object;
- break;
+ String str = (String) iterator.next();
+ if (str.indexOf(expected)!=-1) gotSomethingValid = true;
}
- if (gotit.indexOf("method-call") == -1) {
- String expected = "<recursivepackage{RecursiveCatcher.java}RecursiveCatcher~recursiveCall~I?method-call(void recursivepackage.RecursiveCatcher.recursiveCall(int))";
- fail("Expected '" + expected + "' but got '" + gotit + "'");
+ if (!gotSomethingValid) {
+ fail("Did not find a relationship with the expected data in '"+expected+"'");
}
}