aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authoraclement <aclement>2005-12-12 11:16:49 +0000
committeraclement <aclement>2005-12-12 11:16:49 +0000
commit1435cd1f6af805b0caa3dc786c7536f974023e80 (patch)
treee9e5051cd129e709fa33141405ed81500b41a22e /tests
parent96c97433a198c2960be1afc282081886fb84bb46 (diff)
downloadaspectj-1435cd1f6af805b0caa3dc786c7536f974023e80.tar.gz
aspectj-1435cd1f6af805b0caa3dc786c7536f974023e80.zip
tests and fixes for 119657. from matthew.
Diffstat (limited to 'tests')
-rw-r--r--tests/ltw/aop-defineaspect.xml1
-rw-r--r--tests/src/org/aspectj/systemtest/ajc150/Ajc150Tests.java28
-rw-r--r--tests/src/org/aspectj/systemtest/ajc150/ajc150.xml79
-rw-r--r--tests/src/org/aspectj/systemtest/ajc150/ltw/ltw-tests.xml2
4 files changed, 110 insertions, 0 deletions
diff --git a/tests/ltw/aop-defineaspect.xml b/tests/ltw/aop-defineaspect.xml
index 5fdc064b0..f40bff2c4 100644
--- a/tests/ltw/aop-defineaspect.xml
+++ b/tests/ltw/aop-defineaspect.xml
@@ -4,5 +4,6 @@
<pointcut name="scope" expression="within(Main)"/>
</concrete-aspect>
</aspects>
+ <weaver options="-verbose"/>
</aspectj>
diff --git a/tests/src/org/aspectj/systemtest/ajc150/Ajc150Tests.java b/tests/src/org/aspectj/systemtest/ajc150/Ajc150Tests.java
index de41a5b81..de9881e39 100644
--- a/tests/src/org/aspectj/systemtest/ajc150/Ajc150Tests.java
+++ b/tests/src/org/aspectj/systemtest/ajc150/Ajc150Tests.java
@@ -808,6 +808,34 @@ public class Ajc150Tests extends org.aspectj.testing.XMLBasedAjcTestCase {
runTest("no StringOutOfBoundsException with generic inner aspects");
}
+ public void testIllegalAccessErrorWithAroundAdvice_pr119657() {
+ runTest("IllegalAccessError with around advice on interface method call");
+ }
+
+ public void testIllegalAccessErrorWithAroundAdviceNotSelf_pr119657() {
+ runTest("IllegalAccessError with around advice on interface method call not self");
+ }
+
+ public void testIllegalAccessErrorWithAroundAdviceNoWeaveLTW_pr119657() {
+ runTest("IllegalAccessError with around advice on interface method call using -XnoWeave and LTW");
+ }
+
+ public void testIllegalAccessErrorWithAroundAdviceLTW_pr119657() {
+ runTest("IllegalAccessError with around advice on interface method call using LTW");
+ }
+
+ public void testIllegalAccessErrorWithAroundAdviceNotSelfLTW_pr119657() {
+ runTest("IllegalAccessError with around advice on interface method call not self using LTW");
+ }
+
+ public void testIllegalAccessErrorWithAroundAdviceSelfAndNotSelfLTW_pr119657() {
+ runTest("IllegalAccessError with around advice on interface method call self and not self using LTW");
+ }
+
+ public void testIllegalAccessErrorWithAroundAdviceLTWNoInline_pr119657() {
+ runTest("IllegalAccessError with around advice on interface method call using LTW and -XnoInline");
+ }
+
// helper methods.....
public SyntheticRepository createRepos(File cpentry) {
diff --git a/tests/src/org/aspectj/systemtest/ajc150/ajc150.xml b/tests/src/org/aspectj/systemtest/ajc150/ajc150.xml
index 89fe536a1..99628ba9b 100644
--- a/tests/src/org/aspectj/systemtest/ajc150/ajc150.xml
+++ b/tests/src/org/aspectj/systemtest/ajc150/ajc150.xml
@@ -5935,5 +5935,84 @@
>
</run>
</ajc-test>
+
+ <ajc-test dir="bugs150/pr119657" title="IllegalAccessError with around advice on interface method call">
+ <compile files="services/account/StockQuoteServiceTest.java, services/accountdata/StockAccount.java, services/stockquote/StockQuoteService.java, services/stockquote/StockQuoteServiceImpl.java, services/account/AccountReport.java, accounts/recovery/Recovery.aj"/>
+ <run class="services.account.StockQuoteServiceTest">
+ <stdout>
+ <line text="Recovery.around() call(float services.stockquote.StockQuoteService.getQuote(String))"/>
+ </stdout>
+ </run>
+ <run class="services.account.StockQuoteServiceTest" ltw="aop.xml">
+ <stdout>
+ <line text="Recovery.around() call(float services.stockquote.StockQuoteService.getQuote(String))"/>
+ </stdout>
+ </run>
+ </ajc-test>
+
+ <ajc-test dir="bugs150/pr119657" title="IllegalAccessError with around advice on interface method call not self">
+ <compile files="services/account/StockQuoteServiceTest.java, services/accountdata/StockAccount.java, services/stockquote/StockQuoteService.java, services/stockquote/StockQuoteServiceImpl.java, services/account/AccountReport.java, accounts/recovery/RecoveryNotSelf.aj"/>
+ <run class="services.account.StockQuoteServiceTest">
+ <stdout>
+ <line text="RecoveryNotSelf.around() call(float services.stockquote.StockQuoteService.getQuote(String))"/>
+ </stdout>
+ </run>
+ <run class="services.account.StockQuoteServiceTest" ltw="aop-notself.xml">
+ <stdout>
+ <line text="RecoveryNotSelf.around() call(float services.stockquote.StockQuoteService.getQuote(String))"/>
+ </stdout>
+ </run>
+ </ajc-test>
+
+ <ajc-test dir="bugs150/pr119657" title="IllegalAccessError with around advice on interface method call using -XnoWeave and LTW">
+ <compile files="services/account/StockQuoteServiceTest.java, services/accountdata/StockAccount.java, services/stockquote/StockQuoteService.java, services/stockquote/StockQuoteServiceImpl.java, services/account/AccountReport.java"/>
+ <compile files="accounts/recovery/Recovery.aj" options="-XnoWeave"/>
+ <run class="services.account.StockQuoteServiceTest" ltw="aop.xml">
+ <stdout>
+ <line text="Recovery.around() call(float services.stockquote.StockQuoteService.getQuote(String))"/>
+ </stdout>
+ </run>
+ </ajc-test>
+
+ <ajc-test dir="bugs150/pr119657" title="IllegalAccessError with around advice on interface method call using LTW">
+ <compile files="services/account/StockQuoteServiceTest.java, services/accountdata/StockAccount.java, services/stockquote/StockQuoteService.java, services/stockquote/StockQuoteServiceImpl.java, services/account/AccountReport.java"/>
+ <compile files="accounts/recovery/Recovery.aj"/>
+ <run class="services.account.StockQuoteServiceTest" ltw="aop.xml">
+ <stdout>
+ <line text="Recovery.around() call(float services.stockquote.StockQuoteService.getQuote(String))"/>
+ </stdout>
+ </run>
+ </ajc-test>
+
+ <ajc-test dir="bugs150/pr119657" title="IllegalAccessError with around advice on interface method call not self using LTW">
+ <compile files="services/account/StockQuoteServiceTest.java, services/accountdata/StockAccount.java, services/stockquote/StockQuoteService.java, services/stockquote/StockQuoteServiceImpl.java, services/account/AccountReport.java"/>
+ <compile files="accounts/recovery/RecoveryNotSelf.aj"/>
+ <run class="services.account.StockQuoteServiceTest" ltw="aop-notself.xml">
+ <stdout>
+ <line text="RecoveryNotSelf.around() call(float services.stockquote.StockQuoteService.getQuote(String))"/>
+ </stdout>
+ </run>
+ </ajc-test>
+
+ <ajc-test dir="bugs150/pr119657" title="IllegalAccessError with around advice on interface method call self and not self using LTW">
+ <compile files="services/account/StockQuoteServiceTest.java, services/accountdata/StockAccount.java, services/stockquote/StockQuoteService.java, services/stockquote/StockQuoteServiceImpl.java, services/account/AccountReport.java"/>
+ <compile files="accounts/recovery/Recovery.aj, accounts/recovery/RecoveryNotSelf.aj"/>
+ <run class="services.account.StockQuoteServiceTest" ltw="aop-selfandnotself.xml">
+ <stdout>
+ <line text="Recovery.around() call(float services.stockquote.StockQuoteService.getQuote(String))"/>
+ <line text="RecoveryNotSelf.around() call(float services.stockquote.StockQuoteService.getQuote(String))"/>
+ </stdout>
+ </run>
+ </ajc-test>
+
+ <ajc-test dir="bugs150/pr119657" title="IllegalAccessError with around advice on interface method call using LTW and -XnoInline">
+ <compile files="services/account/StockQuoteServiceTest.java, services/accountdata/StockAccount.java, services/stockquote/StockQuoteService.java, services/stockquote/StockQuoteServiceImpl.java, services/account/AccountReport.java"/>
+ <compile files="accounts/recovery/Recovery.aj"/>
+ <run class="services.account.StockQuoteServiceTest" ltw="aop-noinline.xml">
+ <stdout>
+ <line text="Recovery.around() call(float services.stockquote.StockQuoteService.getQuote(String))"/>
+ </stdout>
+ </run>
+ </ajc-test>
</suite> \ No newline at end of file
diff --git a/tests/src/org/aspectj/systemtest/ajc150/ltw/ltw-tests.xml b/tests/src/org/aspectj/systemtest/ajc150/ltw/ltw-tests.xml
index 284357e42..3610790c0 100644
--- a/tests/src/org/aspectj/systemtest/ajc150/ltw/ltw-tests.xml
+++ b/tests/src/org/aspectj/systemtest/ajc150/ltw/ltw-tests.xml
@@ -132,6 +132,8 @@
<line text="Main.test2"/>
</stdout>
<stderr>
+ <line text="info generating class 'ConcreteAspect'"/>
+ <line text="info weaving 'Main'"/>
<line text="AbstractSuperAspect.before_test1"/>
</stderr>
</run>