From 554e73397c0b80ce32e56cf3adeb6921783e005d Mon Sep 17 00:00:00 2001 From: acolyer Date: Tue, 22 Nov 2005 09:28:09 +0000 Subject: tests and fix for pr103051 :- declare soft and adviceexecution --- tests/bugs150/Pr103051.aj | 12 ++++++++++++ tests/src/org/aspectj/systemtest/ajc150/Ajc150Tests.java | 4 ++++ tests/src/org/aspectj/systemtest/ajc150/ajc150.xml | 4 ++++ 3 files changed, 20 insertions(+) create mode 100644 tests/bugs150/Pr103051.aj (limited to 'tests') diff --git a/tests/bugs150/Pr103051.aj b/tests/bugs150/Pr103051.aj new file mode 100644 index 000000000..99e810431 --- /dev/null +++ b/tests/bugs150/Pr103051.aj @@ -0,0 +1,12 @@ +import java.io.IOException; + +public aspect Pr103051 { + declare soft: IOException: within(Pr103051) && adviceexecution(); + + before() : execution(* main(..)) { + throw new IOException("test"); + } + + public static void main(String args[]) { + } +} \ No newline at end of file diff --git a/tests/src/org/aspectj/systemtest/ajc150/Ajc150Tests.java b/tests/src/org/aspectj/systemtest/ajc150/Ajc150Tests.java index a0cf54cff..d5df0462c 100644 --- a/tests/src/org/aspectj/systemtest/ajc150/Ajc150Tests.java +++ b/tests/src/org/aspectj/systemtest/ajc150/Ajc150Tests.java @@ -725,6 +725,10 @@ public class Ajc150Tests extends org.aspectj.testing.XMLBasedAjcTestCase { public void testReflectionOfAbstractITDs() { runTest("reflection on abstract ITDs (Billing example)"); } + + public void testDeclareSoftWithAdviceExecution() { + runTest("declare soft and adviceexecution"); + } /* * Load-time weaving bugs diff --git a/tests/src/org/aspectj/systemtest/ajc150/ajc150.xml b/tests/src/org/aspectj/systemtest/ajc150/ajc150.xml index 7920840f4..120083cf7 100644 --- a/tests/src/org/aspectj/systemtest/ajc150/ajc150.xml +++ b/tests/src/org/aspectj/systemtest/ajc150/ajc150.xml @@ -80,6 +80,10 @@ + + + + -- cgit v1.2.3