From 3ed33c860ae647660de38ec6a0b6000814c3e1fe Mon Sep 17 00:00:00 2001 From: aclement Date: Mon, 16 Mar 2009 19:53:38 +0000 Subject: [PATCH] 268611: building broken deca code (fix) --- tests/multiIncremental/pr268611/base/src/b/Advises.aj | 8 ++++++++ .../pr268611/base/src/b/IsAdvised.java | 8 ++++++++ .../tools/MultiProjectIncrementalTests.java | 11 +++++++++++ 3 files changed, 27 insertions(+) create mode 100644 tests/multiIncremental/pr268611/base/src/b/Advises.aj create mode 100644 tests/multiIncremental/pr268611/base/src/b/IsAdvised.java diff --git a/tests/multiIncremental/pr268611/base/src/b/Advises.aj b/tests/multiIncremental/pr268611/base/src/b/Advises.aj new file mode 100644 index 000000000..150be4253 --- /dev/null +++ b/tests/multiIncremental/pr268611/base/src/b/Advises.aj @@ -0,0 +1,8 @@ +package b; + +public aspect Advises { + + declare @type: IsAdvised : @Deprecated; + declare @method : IsAdvised.doNothing() : @Deprecated; + declare @field : int IsAdvised.x : @Deprecated; +} diff --git a/tests/multiIncremental/pr268611/base/src/b/IsAdvised.java b/tests/multiIncremental/pr268611/base/src/b/IsAdvised.java new file mode 100644 index 000000000..31e838a13 --- /dev/null +++ b/tests/multiIncremental/pr268611/base/src/b/IsAdvised.java @@ -0,0 +1,8 @@ +package b; + + +public class IsAdvised { + + public void doNothing() {} + int x; +} diff --git a/tests/src/org/aspectj/systemtest/incremental/tools/MultiProjectIncrementalTests.java b/tests/src/org/aspectj/systemtest/incremental/tools/MultiProjectIncrementalTests.java index 9dc0ea6b5..354c742e6 100644 --- a/tests/src/org/aspectj/systemtest/incremental/tools/MultiProjectIncrementalTests.java +++ b/tests/src/org/aspectj/systemtest/incremental/tools/MultiProjectIncrementalTests.java @@ -34,6 +34,7 @@ import org.aspectj.asm.IRelationshipMap; import org.aspectj.asm.internal.ProgramElement; import org.aspectj.asm.internal.Relationship; import org.aspectj.bridge.IMessage; +import org.aspectj.bridge.Message; import org.aspectj.tools.ajc.Ajc; import org.aspectj.util.FileUtil; @@ -50,6 +51,16 @@ import org.aspectj.util.FileUtil; */ public class MultiProjectIncrementalTests extends AbstractMultiProjectIncrementalAjdeInteractionTestbed { + public void testBrokenCodeDeca_268611() { + String p = "pr268611"; + initialiseProject(p); + build(p); + checkWasFullBuild(); + assertEquals(1, getErrorMessages(p).size()); + assertTrue(((Message) getErrorMessages(p).get(0)).getMessage().indexOf( + "Syntax error on token \")\", \"name pattern\" expected") != -1); + } + public void testIncrementalMixin() { String p = "mixin"; initialiseProject(p); -- 2.39.5