diff options
author | aclement <aclement> | 2005-12-13 13:41:47 +0000 |
---|---|---|
committer | aclement <aclement> | 2005-12-13 13:41:47 +0000 |
commit | a29212c28921626874bc1c6cbb38ddc72c773280 (patch) | |
tree | ff1de0348c075bf22ceff71943af4821a043b385 /tests | |
parent | c0fc8fc41653160c06bdc7e8995a5b3a0049ee3a (diff) | |
download | aspectj-a29212c28921626874bc1c6cbb38ddc72c773280.tar.gz aspectj-a29212c28921626874bc1c6cbb38ddc72c773280.zip |
test and fix for 119749
Diffstat (limited to 'tests')
-rw-r--r-- | tests/bugs150/pr119749/InheritedThrows.java | 9 | ||||
-rw-r--r-- | tests/src/org/aspectj/systemtest/ajc150/Ajc150Tests.java | 2 | ||||
-rw-r--r-- | tests/src/org/aspectj/systemtest/ajc150/ajc150.xml | 6 |
3 files changed, 7 insertions, 10 deletions
diff --git a/tests/bugs150/pr119749/InheritedThrows.java b/tests/bugs150/pr119749/InheritedThrows.java index d29a72089..3c3021d5d 100644 --- a/tests/bugs150/pr119749/InheritedThrows.java +++ b/tests/bugs150/pr119749/InheritedThrows.java @@ -1,10 +1,7 @@ public class InheritedThrows { static aspect A { - declare warning : execution (* *.*(..) throws Ex1) : "one"; -// declare warning : execution (* *.*(..) throws Ex2) : "two"; -// declare warning : execution (* *.*(..) throws !(Ex1||Ex2)) : "neither"; -// declare warning : execution (* *.*(..) throws Ex1, Ex2) : "both"; + after() throwing(Ex1 a): execution(* *.*(..) throws Ex1) {} } public static class Ex1 extends Exception {} @@ -16,7 +13,7 @@ public class InheritedThrows { } private static class NestedClass1 implements MyInterface { - public void m() throws Ex1 {} + public void m() throws Ex1 {} // MATCHES HERE } private static class NestedClass2 implements MyInterface { @@ -24,7 +21,7 @@ public class InheritedThrows { } private static class NestedClassBoth implements MyInterface { - public void m() throws Ex1, Ex2 {} + public void m() throws Ex1, Ex2 {} // MATCHES HERE } private static class NestedClassNeither implements MyInterface { diff --git a/tests/src/org/aspectj/systemtest/ajc150/Ajc150Tests.java b/tests/src/org/aspectj/systemtest/ajc150/Ajc150Tests.java index 1ff229944..ba040ceac 100644 --- a/tests/src/org/aspectj/systemtest/ajc150/Ajc150Tests.java +++ b/tests/src/org/aspectj/systemtest/ajc150/Ajc150Tests.java @@ -52,7 +52,7 @@ public class Ajc150Tests extends org.aspectj.testing.XMLBasedAjcTestCase { public void testCunningDeclareParents_pr92311() { runTest("cunning declare parents");} public void testGenericITDsAndAbstractMethodError_pr102357() { runTest("generic itds and abstract method error");} */ - //public void testIncorrectSignatureMatchingWithExceptions_pr119749() { runTest("incorrect exception signature matching");} + public void testIncorrectSignatureMatchingWithExceptions_pr119749() { runTest("incorrect exception signature matching");} public void testGeneratingCodeForAnOldRuntime_pr116679_1() { runTest("generating code for a 1.2.1 runtime - 1");} public void testGeneratingCodeForAnOldRuntime_pr116679_2() { runTest("generating code for a 1.2.1 runtime - 2");} public void testAmbiguousMethod_pr118599_1() { runTest("ambiguous method when binary weaving - 1");} diff --git a/tests/src/org/aspectj/systemtest/ajc150/ajc150.xml b/tests/src/org/aspectj/systemtest/ajc150/ajc150.xml index 790dca6f9..a73365dc2 100644 --- a/tests/src/org/aspectj/systemtest/ajc150/ajc150.xml +++ b/tests/src/org/aspectj/systemtest/ajc150/ajc150.xml @@ -136,9 +136,9 @@ </ajc-test> <ajc-test dir="bugs150/pr119749" pr="119749" title="incorrect exception signature matching"> - <compile files="InheritedThrows.java" options=""> - <message kind="warning" line="19" text="one"/> - <message kind="warning" line="27" text="one"/> + <compile files="InheritedThrows.java" options="-showWeaveInfo"> + <message kind="weave" text="Join point 'method-execution(void InheritedThrows$NestedClassBoth.m())' in Type 'InheritedThrows$NestedClassBoth' (InheritedThrows.java:24) advised by afterThrowing advice from 'InheritedThrows$A' (InheritedThrows.java:4)"/> + <message kind="weave" text="Join point 'method-execution(void InheritedThrows$NestedClass1.m())' in Type 'InheritedThrows$NestedClass1' (InheritedThrows.java:16) advised by afterThrowing advice from 'InheritedThrows$A' (InheritedThrows.java:4)"/> </compile> </ajc-test> |