Browse Source

288064: innerclass attribute usage

tags/V1_6_7
aclement 14 years ago
parent
commit
a36fdb2e63

+ 7
- 0
tests/bugs167/pr288064/Aspect.java View File

@@ -0,0 +1,7 @@
package test;
aspect Aspect {
before() : call(void test..*(..)) {
System.out.println("advice");
}
}


+ 8
- 0
tests/bugs167/pr288064/Main.java View File

@@ -0,0 +1,8 @@
package test;
public class Main {
public static void main(String[] args){
Outer.Inner$1<Integer> inner = new Outer.Inner$1<Integer>();
inner.innerMethod(1);
}
}


+ 8
- 0
tests/bugs167/pr288064/Outer.java View File

@@ -0,0 +1,8 @@
package test;
public class Outer {
public static class Inner$1<T> {
void innerMethod(T arg){
System.out.println("method");
}
}
}

+ 5
- 0
tests/bugs167/pr288064/aop.xml View File

@@ -0,0 +1,5 @@
<aspectj>
<aspects>
<aspect name="test.Aspect"/>
</aspects>
</aspectj>

+ 2
- 0
tests/src/org/aspectj/systemtest/AllTests16.java View File

@@ -13,6 +13,7 @@ import org.aspectj.systemtest.ajc163.AllTestsAspectJ163;
import org.aspectj.systemtest.ajc164.AllTestsAspectJ164;
import org.aspectj.systemtest.ajc165.AllTestsAspectJ165;
import org.aspectj.systemtest.ajc166.AllTestsAspectJ166;
import org.aspectj.systemtest.ajc167.AllTestsAspectJ167;

public class AllTests16 {

@@ -27,6 +28,7 @@ public class AllTests16 {
suite.addTest(AllTestsAspectJ164.suite());
suite.addTest(AllTestsAspectJ165.suite());
suite.addTest(AllTestsAspectJ166.suite());
suite.addTest(AllTestsAspectJ167.suite());
suite.addTest(AllTests15.suite());
// $JUnit-END$
return suite;

+ 1
- 1
tests/src/org/aspectj/systemtest/ajc166/AllTestsAspectJ166.java View File

@@ -16,7 +16,7 @@ import junit.framework.TestSuite;
public class AllTestsAspectJ166 {

public static Test suite() {
TestSuite suite = new TestSuite("AspectJ 1.6.5 tests");
TestSuite suite = new TestSuite("AspectJ 1.6.6 tests");
// $JUnit-BEGIN$
suite.addTest(Ajc166Tests.suite());
// $JUnit-END$

+ 39
- 0
tests/src/org/aspectj/systemtest/ajc167/Ajc167Tests.java View File

@@ -0,0 +1,39 @@
/*******************************************************************************
* Copyright (c) 2008 Contributors
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
* Andy Clement - initial API and implementation
*******************************************************************************/
package org.aspectj.systemtest.ajc167;

import java.io.File;

import junit.framework.Test;

import org.aspectj.testing.XMLBasedAjcTestCase;

public class Ajc167Tests extends org.aspectj.testing.XMLBasedAjcTestCase {

public void testScalaOuterClassNames_pr288064() {
runTest("outer class names - scala");
}

public void testScalaOuterClassNames_pr288064_ltw() {
runTest("outer class names - scala - ltw");
}

// ---

public static Test suite() {
return XMLBasedAjcTestCase.loadSuite(Ajc167Tests.class);
}

protected File getSpecFile() {
return new File("../tests/src/org/aspectj/systemtest/ajc167/ajc167.xml");
}

}

+ 25
- 0
tests/src/org/aspectj/systemtest/ajc167/AllTestsAspectJ167.java View File

@@ -0,0 +1,25 @@
/*******************************************************************************
* Copyright (c) 2008 Contributors
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
* Andy Clement - initial API and implementation
*******************************************************************************/
package org.aspectj.systemtest.ajc167;

import junit.framework.Test;
import junit.framework.TestSuite;

public class AllTestsAspectJ167 {

public static Test suite() {
TestSuite suite = new TestSuite("AspectJ 1.6.7 tests");
// $JUnit-BEGIN$
suite.addTest(Ajc167Tests.suite());
// $JUnit-END$
return suite;
}
}

+ 26
- 0
tests/src/org/aspectj/systemtest/ajc167/ajc167.xml View File

@@ -0,0 +1,26 @@
<!DOCTYPE suite SYSTEM "../tests/ajcTestSuite.dtd"[]>

<suite>

<ajc-test dir="bugs167/pr288064" title="outer class names - scala">
<compile files="Main.java Outer.java Aspect.java" options="-1.5"/>
<run class="test.Main">
<stdout>
<line text="advice"/>
<line text="method"/>
</stdout>
</run>
</ajc-test>
<ajc-test dir="bugs167/pr288064" title="outer class names - scala - ltw">
<compile files="Main.java Outer.java" outjar="app.jar" options="-1.5"/>
<compile files="Aspect.java" outjar="asp.jar" options="-Xlint:ignore -1.5"/>
<run class="test.Main" classpath="app.jar;asp.jar" ltw="aop.xml">
<stdout>
<line text="advice"/>
<line text="method"/>
</stdout>
</run>
</ajc-test>
</suite>

Loading…
Cancel
Save