summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjhugunin <jhugunin>2003-05-01 18:48:06 +0000
committerjhugunin <jhugunin>2003-05-01 18:48:06 +0000
commit7e47f0f2fa4e805f11a67f953aeeeb3e959fcc3d (patch)
treea5923ed58bf1ca29a096b494d19d8742cec8dc0c
parentaaca8abb5e65355985f4cbef492d7e5e8272a1c7 (diff)
downloadaspectj-7e47f0f2fa4e805f11a67f953aeeeb3e959fcc3d.tar.gz
aspectj-7e47f0f2fa4e805f11a67f953aeeeb3e959fcc3d.zip
added test that deprecation warnings are not shown unless asked for
modifying option setting to make that test pass
-rw-r--r--org.aspectj.ajdt.core/src/org/aspectj/ajdt/ajc/BuildArgParser.java4
-rw-r--r--tests/ajcTests.xml7
-rw-r--r--tests/jimTests.xml38
3 files changed, 21 insertions, 28 deletions
diff --git a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/ajc/BuildArgParser.java b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/ajc/BuildArgParser.java
index 8d387a99d..6955b4744 100644
--- a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/ajc/BuildArgParser.java
+++ b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/ajc/BuildArgParser.java
@@ -116,7 +116,9 @@ public class BuildArgParser extends Main {
}
List javaArgList = parser.getUnparsedArgs();
- javaArgList.add("-warn:deprecation"); //!!! need to make this more flexible
+ // disable all special eclipse warnings by default
+ //??? might want to instead override getDefaultOptions()
+ javaArgList.add(0, "-warn:none");
if (javaArgList.size() != 0) {
super.configure((String[])javaArgList.toArray(new String[javaArgList.size()]));
}
diff --git a/tests/ajcTests.xml b/tests/ajcTests.xml
index 8c4c21639..b7ad971d5 100644
--- a/tests/ajcTests.xml
+++ b/tests/ajcTests.xml
@@ -5198,6 +5198,13 @@
<message kind="warning" line="10"/>
</compile>
</ajc-test>
+
+ <ajc-test dir="options"
+ title="options -warn:deprecation not enabled">
+ <compile files="WarnDeprecated.java"
+ options="!eclipse">
+ </compile>
+ </ajc-test>
<!-- .................................... -Xlint tests -->
<!-- ............... positive -Xlint tests -->
diff --git a/tests/jimTests.xml b/tests/jimTests.xml
index a7b32080d..c071015d0 100644
--- a/tests/jimTests.xml
+++ b/tests/jimTests.xml
@@ -1,32 +1,16 @@
<!DOCTYPE suite SYSTEM "../tests/ajcTestSuite.dtd">
<suite>
-
- <ajc-test dir="bugs/interSpecials" title="IllegalAccessError while accessing introduced variable / 1.1rc1"
- pr="36110">
- <compile files="p1/C.java,p2/A1.java"/>
- <run class="p2.A1"/>
+ <ajc-test dir="options"
+ title="options -warn:deprecation">
+ <compile files="WarnDeprecated.java"
+ options="!eclipse,-warn:deprecation">
+ <message kind="warning" line="10"/>
+ </compile>
</ajc-test>
-
- <ajc-test dir="bugs/interSpecials" title="testing that assert works like .class"
- pr="36110">
- <compile files="p1/C.java,p2/A2.java" options="-source14"/>
- <run class="p2.A2" vm="1.4"/>
+ <ajc-test dir="options"
+ title="options -warn:deprecation turned off">
+ <compile files="WarnDeprecated.java"
+ options="!eclipse">
+ </compile>
</ajc-test>
-
- <!--
-
- <ajc-test dir="options/injars/simple"
- title="options -injars">
- <compile files="Simple.java,main.jar"
- options="!eclipse"/>
- <run class="Main"/>
- </ajc-test>
-
-
- <ajc-test dir="new" pr="885"
- title="source locations within expressions">
- <compile files="SourceLocationWithinExpr.java" options="-1.4"/>
- <run class="SourceLocationWithinExpr"/>
- </ajc-test>
- -->
</suite> \ No newline at end of file