From 14908174fcb2a52819e8c022424938ff9f2c9876 Mon Sep 17 00:00:00 2001 From: acolyer Date: Fri, 23 Jan 2004 12:10:58 +0000 Subject: [PATCH] spring cleaning in advance of 1.2 enhancements: removed unused imports, local variables, and private methods (still there, just commented out). --- .../src/org/aspectj/testing/Tester.java | 2 +- .../internal/tools/ant/taskdefs/Ajctest.java | 180 +++++++++--------- .../aspectj/testing/ajde/CompileCommand.java | 12 +- .../harness/bridge/AbstractRunSpec.java | 40 ++-- .../harness/bridge/AjcMessageHandler.java | 2 +- .../testing/harness/bridge/AjcTest.java | 6 +- .../testing/harness/bridge/CompilerRun.java | 32 ++-- .../testing/harness/bridge/DirChanges.java | 8 +- .../harness/bridge/FlatSuiteReader.java | 2 +- .../testing/harness/bridge/Globals.java | 2 +- .../harness/bridge/IncCompilerRun.java | 22 +-- .../harness/bridge/RunSpecIterator.java | 2 +- .../testing/harness/bridge/Validator.java | 2 +- .../src/org/aspectj/testing/run/Runner.java | 4 +- .../taskdefs/AjcTaskCompileCommand.java | 8 +- .../org/aspectj/testing/util/BridgeUtil.java | 8 +- .../org/aspectj/testing/util/LangUtil.java | 12 +- .../org/aspectj/testing/util/LinkCheck.java | 38 ++-- .../org/aspectj/testing/util/RunUtils.java | 2 +- .../aspectj/testing/util/StreamsHandler.java | 2 +- .../org/aspectj/testing/util/TestDiffs.java | 2 +- .../aspectj/testing/util/options/Option.java | 6 +- .../aspectj/testing/util/options/Options.java | 4 +- .../aspectj/testing/util/options/Values.java | 2 +- .../aspectj/testing/xml/AjcSpecXmlReader.java | 118 ++++++------ .../testing/xml/MessageListXmlReader.java | 42 ++-- .../org/aspectj/testing/xml/SoftMessage.java | 4 +- .../org/aspectj/testing/xml/XMLWriter.java | 2 +- .../testing/harness/bridge/AjcSpecTest.java | 2 +- .../harness/bridge/CompilerRunSpecTest.java | 4 +- .../harness/bridge/CompilerRunTest.java | 8 +- .../testing/harness/bridge/ParseTestCase.java | 6 +- .../taskdefs/AjcTaskCompileCommandTest.java | 2 +- .../aspectj/testing/util/LangUtilTest.java | 2 +- .../testing/util/options/OptionChecker.java | 6 +- .../testing/util/options/OptionsTest.java | 2 +- .../testing/xml/AjcSpecXmlReaderTest.java | 4 +- 37 files changed, 301 insertions(+), 301 deletions(-) diff --git a/testing-client/src/org/aspectj/testing/Tester.java b/testing-client/src/org/aspectj/testing/Tester.java index 6d4a278ae..07c9bff17 100644 --- a/testing-client/src/org/aspectj/testing/Tester.java +++ b/testing-client/src/org/aspectj/testing/Tester.java @@ -960,7 +960,7 @@ public class Tester { final boolean failed = fail || (null != thrown); IMessage.Kind kind = (failed ? IMessage.FAIL : IMessage.INFO); IMessage m = new Message(message, kind, thrown, null); - final boolean handled = messageHandler.handleMessage(m); + /*final boolean handled = */messageHandler.handleMessage(m); } // private static void resofhandle(String message, Throwable thrown, boolean fail) { // /* If FAIL and the message handler returns false (normally), diff --git a/testing/src/org/aspectj/internal/tools/ant/taskdefs/Ajctest.java b/testing/src/org/aspectj/internal/tools/ant/taskdefs/Ajctest.java index 709bbc5c2..39e22a98a 100644 --- a/testing/src/org/aspectj/internal/tools/ant/taskdefs/Ajctest.java +++ b/testing/src/org/aspectj/internal/tools/ant/taskdefs/Ajctest.java @@ -35,7 +35,7 @@ import java.io.PrintStream; import java.io.PrintWriter; import java.io.StringWriter; import java.text.DateFormat; -import java.util.Collection; +//import java.util.Collection; import java.util.Date; import java.util.HashMap; import java.util.Iterator; @@ -67,7 +67,7 @@ import org.apache.tools.ant.Project; import org.apache.tools.ant.Target; import org.apache.tools.ant.Task; import org.apache.tools.ant.taskdefs.Delete; -import org.apache.tools.ant.taskdefs.ExecTask; +//import org.apache.tools.ant.taskdefs.ExecTask; import org.apache.tools.ant.taskdefs.Java; import org.apache.tools.ant.taskdefs.LogOutputStream; import org.apache.tools.ant.taskdefs.Mkdir; @@ -117,7 +117,7 @@ public class Ajctest extends Task implements PropertyChangeListener { private Stats ajdocStats = new Stats(); private Stats ajcStats = new Stats(); private Stats runStats = new Stats(); - private Stats errorStats = new Stats(); +// private Stats errorStats = new Stats(); private static final String NO_TESTID = "NONE"; private File workingdir = new File("ajworkingdir"); //XXX @@ -1067,22 +1067,22 @@ public class Ajctest extends Task implements PropertyChangeListener { // class Run // todo: need to run in a wrapper which report non-zero int on exception // todo: unused method? see executeJava above. - private int java(String classname, Collection args) throws BuildException { - Java java = (Java)project.createTask("java"); - java.setClassname(classname); - for (Iterator i = args.iterator(); i.hasNext();) { - Object o = i.next(); - Commandline.Argument arg = java.createArg(); - if (o instanceof File) { - arg.setFile((File)o); - } else if (o instanceof Path) { - arg.setPath((Path)o); - } else { - arg.setValue(o+""); - } - } - return java.executeJava(); - } +// private int java(String classname, Collection args) throws BuildException { +// Java java = (Java)project.createTask("java"); +// java.setClassname(classname); +// for (Iterator i = args.iterator(); i.hasNext();) { +// Object o = i.next(); +// Commandline.Argument arg = java.createArg(); +// if (o instanceof File) { +// arg.setFile((File)o); +// } else if (o instanceof Path) { +// arg.setPath((Path)o); +// } else { +// arg.setValue(o+""); +// } +// } +// return java.executeJava(); +// } private static List allErrors = new Vector(); private List errors = new Vector(); @@ -1547,77 +1547,77 @@ public class Ajctest extends Task implements PropertyChangeListener { } /** implement invocation of ajc */ - private void java(Testset testset, List args) throws BuildException { - Java java = (Java)project.createTask("java"); - java.setClassname("org.aspectj.tools.ajc.Main"); - if (classpath != null) { - java.setClasspath(classpath); - } - for (Iterator iter = args.iterator(); iter.hasNext();) { - Arg arg = (Arg)iter.next(); - if (arg.isj) { - java.createJvmarg().setValue(arg.name); - if (!arg.value.equals("")) { - java.createJvmarg().setValue(arg.value); - } - } - } - for (Iterator iter = args.iterator(); iter.hasNext();) { - Arg arg = (Arg)iter.next(); - if (!arg.isj) { - java.createArg().setValue(arg.name); - if (!arg.value.equals("")) { - java.createArg().setValue(arg.value); - } - } - } - for (Iterator iter = testset.files.iterator(); iter.hasNext();) { - java.createArg().setFile((File)iter.next()); - } - for (Iterator iter = testset.argfiles.iterator(); iter.hasNext();) { - java.createArg().setValue("-argfile"); - java.createArg().setFile((File)iter.next()); - } - java.setFork(true); - java.execute(); - } - - private void exec(Testset testset, List args) throws BuildException { - ExecTask exec = (ExecTask)project.createTask("exec"); - exec.setExecutable("java"); - if (classpath != null) { - exec.createArg().setValue("-classpath"); - exec.createArg().setPath(classpath); - } - for (Iterator iter = args.iterator(); iter.hasNext();) { - Arg arg = (Arg)iter.next(); - if (arg.isj) { - exec.createArg().setValue(arg.name); - if (!arg.value.equals("")) { - exec.createArg().setValue(arg.value); - } - } - } - exec.createArg().setValue("org.aspectj.tools.ajc.Main"); - for (Iterator iter = args.iterator(); iter.hasNext();) { - Arg arg = (Arg)iter.next(); - if (!arg.isj) { - exec.createArg().setValue(arg.name); - if (!arg.value.equals("")) { - exec.createArg().setValue(arg.value); - } - } - } - for (Iterator iter = testset.files.iterator(); iter.hasNext();) { - exec.createArg().setFile((File)iter.next()); - } - for (Iterator iter = testset.argfiles.iterator(); iter.hasNext();) { - exec.createArg().setValue("-argfile"); - exec.createArg().setFile((File)iter.next()); - } - exec.execute(); - } - +// private void java(Testset testset, List args) throws BuildException { +// Java java = (Java)project.createTask("java"); +// java.setClassname("org.aspectj.tools.ajc.Main"); +// if (classpath != null) { +// java.setClasspath(classpath); +// } +// for (Iterator iter = args.iterator(); iter.hasNext();) { +// Arg arg = (Arg)iter.next(); +// if (arg.isj) { +// java.createJvmarg().setValue(arg.name); +// if (!arg.value.equals("")) { +// java.createJvmarg().setValue(arg.value); +// } +// } +// } +// for (Iterator iter = args.iterator(); iter.hasNext();) { +// Arg arg = (Arg)iter.next(); +// if (!arg.isj) { +// java.createArg().setValue(arg.name); +// if (!arg.value.equals("")) { +// java.createArg().setValue(arg.value); +// } +// } +// } +// for (Iterator iter = testset.files.iterator(); iter.hasNext();) { +// java.createArg().setFile((File)iter.next()); +// } +// for (Iterator iter = testset.argfiles.iterator(); iter.hasNext();) { +// java.createArg().setValue("-argfile"); +// java.createArg().setFile((File)iter.next()); +// } +// java.setFork(true); +// java.execute(); +// } +// +// private void exec(Testset testset, List args) throws BuildException { +// ExecTask exec = (ExecTask)project.createTask("exec"); +// exec.setExecutable("java"); +// if (classpath != null) { +// exec.createArg().setValue("-classpath"); +// exec.createArg().setPath(classpath); +// } +// for (Iterator iter = args.iterator(); iter.hasNext();) { +// Arg arg = (Arg)iter.next(); +// if (arg.isj) { +// exec.createArg().setValue(arg.name); +// if (!arg.value.equals("")) { +// exec.createArg().setValue(arg.value); +// } +// } +// } +// exec.createArg().setValue("org.aspectj.tools.ajc.Main"); +// for (Iterator iter = args.iterator(); iter.hasNext();) { +// Arg arg = (Arg)iter.next(); +// if (!arg.isj) { +// exec.createArg().setValue(arg.name); +// if (!arg.value.equals("")) { +// exec.createArg().setValue(arg.value); +// } +// } +// } +// for (Iterator iter = testset.files.iterator(); iter.hasNext();) { +// exec.createArg().setFile((File)iter.next()); +// } +// for (Iterator iter = testset.argfiles.iterator(); iter.hasNext();) { +// exec.createArg().setValue("-argfile"); +// exec.createArg().setFile((File)iter.next()); +// } +// exec.execute(); +// } +// public void handle(Throwable t) { log("handling " + t); if (t != null) t.printStackTrace(); diff --git a/testing/src/org/aspectj/testing/ajde/CompileCommand.java b/testing/src/org/aspectj/testing/ajde/CompileCommand.java index b670ae485..fd69ab9de 100644 --- a/testing/src/org/aspectj/testing/ajde/CompileCommand.java +++ b/testing/src/org/aspectj/testing/ajde/CompileCommand.java @@ -200,12 +200,12 @@ public class CompileCommand implements ICommand { } } - private Object makeLoggingProxy(Class interfac) { - return Proxy.newProxyInstance( - interfac.getClassLoader(), - new Class[] { interfac }, - loggingProxy); - } +// private Object makeLoggingProxy(Class interfac) { +// return Proxy.newProxyInstance( +// interfac.getClassLoader(), +// new Class[] { interfac }, +// loggingProxy); +// } private Object makeProxy(Class interfac) { return Proxy.newProxyInstance( diff --git a/testing/src/org/aspectj/testing/harness/bridge/AbstractRunSpec.java b/testing/src/org/aspectj/testing/harness/bridge/AbstractRunSpec.java index b1e3051e1..a23287349 100644 --- a/testing/src/org/aspectj/testing/harness/bridge/AbstractRunSpec.java +++ b/testing/src/org/aspectj/testing/harness/bridge/AbstractRunSpec.java @@ -30,7 +30,7 @@ import org.aspectj.bridge.ISourceLocation; import org.aspectj.bridge.MessageHandler; import org.aspectj.bridge.MessageUtil; import org.aspectj.testing.run.IRunIterator; -import org.aspectj.testing.util.*; +//import org.aspectj.testing.util.*; import org.aspectj.testing.util.BridgeUtil; import org.aspectj.testing.util.options.*; import org.aspectj.testing.util.options.Option.InvalidInputException; @@ -576,23 +576,23 @@ abstract public class AbstractRunSpec implements IRunSpec { // XXX use MessageHa } } - /** @return null if value is null or name="{value}" otherwise */ - private String makeAttr(XMLWriter out, String name, String value) { - if (null == value) { - return null; - } - return XMLWriter.makeAttribute(name, value); - } - - /** @return null if list is null or empty or name="{flattenedList}" otherwise */ - private String makeAttr(XMLWriter out, String name, List list) { - if (LangUtil.isEmpty(list)) { - return null; - } - String flat = XMLWriter.flattenList(list); - return XMLWriter.makeAttribute(name, flat); - } - +// /** @return null if value is null or name="{value}" otherwise */ +// private String makeAttr(XMLWriter out, String name, String value) { +// if (null == value) { +// return null; +// } +// return XMLWriter.makeAttribute(name, value); +// } +// +// /** @return null if list is null or empty or name="{flattenedList}" otherwise */ +// private String makeAttr(XMLWriter out, String name, List list) { +// if (LangUtil.isEmpty(list)) { +// return null; +// } +// String flat = XMLWriter.flattenList(list); +// return XMLWriter.makeAttribute(name, flat); +// } +// /** @return true if writeAttributes(..) will produce any output */ protected boolean haveAttributes() { return ((!LangUtil.isEmpty(xmlNames.descriptionName) @@ -981,7 +981,7 @@ abstract public class AbstractRunSpec implements IRunSpec { // XXX use MessageHa if (LangUtil.isEmpty(parentOptions)) { return result; } - boolean haveOption = false; +// boolean haveOption = false; String[] parents = (String[]) parentOptions.toArray(new String[0]); try { result = validOptions.acceptInput(parents); @@ -1031,7 +1031,7 @@ abstract public class AbstractRunSpec implements IRunSpec { // XXX use MessageHa return new String[0]; } ArrayList result = new ArrayList(); - boolean haveOption = false; +// boolean haveOption = false; for (int i = 0; i < validOptions.length; i++) { String option = validOptions[i]; if (LangUtil.isEmpty(option)) { diff --git a/testing/src/org/aspectj/testing/harness/bridge/AjcMessageHandler.java b/testing/src/org/aspectj/testing/harness/bridge/AjcMessageHandler.java index dc19ea2b9..acb93c822 100644 --- a/testing/src/org/aspectj/testing/harness/bridge/AjcMessageHandler.java +++ b/testing/src/org/aspectj/testing/harness/bridge/AjcMessageHandler.java @@ -25,7 +25,7 @@ import org.aspectj.bridge.IMessageHandler; import org.aspectj.bridge.IMessageHolder; import org.aspectj.bridge.MessageHandler; import org.aspectj.bridge.MessageUtil; -import org.aspectj.bridge.IMessage.Kind; +//import org.aspectj.bridge.IMessage.Kind; import org.aspectj.testing.util.BridgeUtil; import org.aspectj.testing.util.Diffs; import org.aspectj.util.LangUtil; diff --git a/testing/src/org/aspectj/testing/harness/bridge/AjcTest.java b/testing/src/org/aspectj/testing/harness/bridge/AjcTest.java index e359389bf..48f3ad196 100644 --- a/testing/src/org/aspectj/testing/harness/bridge/AjcTest.java +++ b/testing/src/org/aspectj/testing/harness/bridge/AjcTest.java @@ -21,7 +21,7 @@ import java.util.Collections; import java.util.Iterator; import java.util.List; -import org.aspectj.bridge.*; +//import org.aspectj.bridge.*; import org.aspectj.bridge.IMessageHandler; import org.aspectj.bridge.ISourceLocation; import org.aspectj.testing.run.IRunIterator; @@ -525,8 +525,8 @@ public class AjcTest extends RunSpecIterator { * skip dirChanges, skip messages and do children * (though we do children directly). */ - private static final XMLNames NAMES = new XMLNames(XMLNames.DEFAULT, - null, null, null, null, "", null, "", "", true, true, false); +// private static final XMLNames NAMES = new XMLNames(XMLNames.DEFAULT, +// null, null, null, null, "", null, "", "", true, true, false); File suiteDir; public Spec() { super(XMLNAME, false); // do not skip this even if children skip diff --git a/testing/src/org/aspectj/testing/harness/bridge/CompilerRun.java b/testing/src/org/aspectj/testing/harness/bridge/CompilerRun.java index e18aa09e6..efa60f1c1 100644 --- a/testing/src/org/aspectj/testing/harness/bridge/CompilerRun.java +++ b/testing/src/org/aspectj/testing/harness/bridge/CompilerRun.java @@ -413,9 +413,9 @@ public class CompilerRun implements IAjcRun { MessageUtil.abort(status, spec.testSetup.failureReason); return false; } - boolean ignoreWarnings = - (spec.testSetup.ignoreWarningsSet - && spec.testSetup.ignoreWarnings); +// boolean ignoreWarnings = +// (spec.testSetup.ignoreWarningsSet +// && spec.testSetup.ignoreWarnings); AjcMessageHandler handler = new AjcMessageHandler(spec.getMessages()); handler.init(); @@ -688,18 +688,18 @@ public class CompilerRun implements IAjcRun { } /** @return true if javac is available on the classpath */ - private static boolean haveJavac() { // XXX copy/paste from JavaCWrapper.java - Class compilerClass = null; - try { - compilerClass = Class.forName("com.sun.tools.javac.Main"); - } catch (ClassNotFoundException ce1) { - try { - compilerClass = Class.forName("sun.tools.javac.Main"); - } catch (ClassNotFoundException ce2) { - } - } - return (null != compilerClass); - } +// private static boolean haveJavac() { // XXX copy/paste from JavaCWrapper.java +// Class compilerClass = null; +// try { +// compilerClass = Class.forName("com.sun.tools.javac.Main"); +// } catch (ClassNotFoundException ce1) { +// try { +// compilerClass = Class.forName("sun.tools.javac.Main"); +// } catch (ClassNotFoundException ce2) { +// } +// } +// return (null != compilerClass); +// } protected String compiler; @@ -1035,7 +1035,7 @@ public class CompilerRun implements IAjcRun { if (null != source) { String sourceVersion = source.unflatten()[1]; ArrayList toAdd = new ArrayList(); - String err = + /*String err =*/ updateBootclasspathForSourceVersion( sourceVersion, spec.compiler, diff --git a/testing/src/org/aspectj/testing/harness/bridge/DirChanges.java b/testing/src/org/aspectj/testing/harness/bridge/DirChanges.java index 873302d12..5e09e68be 100644 --- a/testing/src/org/aspectj/testing/harness/bridge/DirChanges.java +++ b/testing/src/org/aspectj/testing/harness/bridge/DirChanges.java @@ -190,7 +190,7 @@ public class DirChanges { boolean exists, List pathList, boolean doCompare) { - boolean expectStartEarlier = true; +// boolean expectStartEarlier = true; return exists(label, exists, pathList,doCompare, true); } protected boolean exists( @@ -201,9 +201,9 @@ public class DirChanges { boolean expectStartEarlier) { boolean result = true; if (!LangUtil.isEmpty(pathList)) { - final File expDir = ((!doCompare || (null == spec.expDir)) - ? null - : new File(baseDir, spec.expDir)); +// final File expDir = ((!doCompare || (null == spec.expDir)) +// ? null +// : new File(baseDir, spec.expDir)); for (Iterator iter = pathList.iterator(); iter.hasNext();) { final String entry = (String) iter.next() ; String path = entry ; diff --git a/testing/src/org/aspectj/testing/harness/bridge/FlatSuiteReader.java b/testing/src/org/aspectj/testing/harness/bridge/FlatSuiteReader.java index cdfe4d542..2ef5a61a8 100644 --- a/testing/src/org/aspectj/testing/harness/bridge/FlatSuiteReader.java +++ b/testing/src/org/aspectj/testing/harness/bridge/FlatSuiteReader.java @@ -104,7 +104,7 @@ public class FlatSuiteReader implements SFileReader.Maker { //final String baseDir = reader.getFile().getParent(); String line; String[] words; - boolean isRequired = true; +// boolean isRequired = true; final int startLine = reader.getLineNumber() - 1; diff --git a/testing/src/org/aspectj/testing/harness/bridge/Globals.java b/testing/src/org/aspectj/testing/harness/bridge/Globals.java index e4060d50a..09f0edc6a 100644 --- a/testing/src/org/aspectj/testing/harness/bridge/Globals.java +++ b/testing/src/org/aspectj/testing/harness/bridge/Globals.java @@ -58,7 +58,7 @@ public class Globals { J2SE14_RTJAR = getRtJarFor(J2SE14_RTJAR_NAME, "c:/home/apps/jdk14"); - String forkSpec = getSystemProperty(FORK_NAME, null); +// String forkSpec = getSystemProperty(FORK_NAME, null); globalsValid = (FileUtil.canReadFile(F_testingclient_jar) && FileUtil.canReadFile(F_aspectjrt_jar) diff --git a/testing/src/org/aspectj/testing/harness/bridge/IncCompilerRun.java b/testing/src/org/aspectj/testing/harness/bridge/IncCompilerRun.java index b06430e61..dddfbdd5a 100644 --- a/testing/src/org/aspectj/testing/harness/bridge/IncCompilerRun.java +++ b/testing/src/org/aspectj/testing/harness/bridge/IncCompilerRun.java @@ -16,14 +16,14 @@ package org.aspectj.testing.harness.bridge; import java.io.File; import java.io.FileFilter; import java.io.IOException; -import java.util.*; +//import java.util.*; import java.util.ArrayList; import java.util.Arrays; -import java.util.Collections; -import java.util.List; +//import java.util.Collections; +//import java.util.List; import org.aspectj.bridge.ICommand; -import org.aspectj.bridge.IMessage; +//import org.aspectj.bridge.IMessage; import org.aspectj.bridge.MessageUtil; import org.aspectj.testing.ajde.CompileCommand; import org.aspectj.testing.run.IRunIterator; @@ -224,7 +224,7 @@ public class IncCompilerRun implements IAjcRun { MessageUtil.info(handler, "fresh not supported by compiler: " + compiler); } } - final long startTime = System.currentTimeMillis(); +// final long startTime = System.currentTimeMillis(); commandResult = compiler.repeatCommand(handler); // XXX disabled LangUtil.throwIaxIfNotAllAssignable(actualRecompiled, File.class, "recompiled"); report = true; @@ -258,9 +258,9 @@ public class IncCompilerRun implements IAjcRun { return result; } - private boolean hasFile(ArrayList changed, File f) { - return changed.contains(f); // d - } +// private boolean hasFile(ArrayList changed, File f) { +// return changed.contains(f); // d +// } public String toString() { @@ -285,9 +285,9 @@ public class IncCompilerRun implements IAjcRun { * skip staging (always true), skip badInput (irrelevant) * do dirChanges, do messages but skip children. */ - private static final XMLNames NAMES = new XMLNames(XMLNames.DEFAULT, - "", "", null, "", "classes", null, "", "", false, false, true); - +// private static final XMLNames NAMES = new XMLNames(XMLNames.DEFAULT, +// "", "", null, "", "classes", null, "", "", false, false, true); +// /** identifies files this run owns, so {name}.{tag}.java maps to {name}.java */ String tag; diff --git a/testing/src/org/aspectj/testing/harness/bridge/RunSpecIterator.java b/testing/src/org/aspectj/testing/harness/bridge/RunSpecIterator.java index 3e1f536f5..4525be631 100644 --- a/testing/src/org/aspectj/testing/harness/bridge/RunSpecIterator.java +++ b/testing/src/org/aspectj/testing/harness/bridge/RunSpecIterator.java @@ -68,7 +68,7 @@ public class RunSpecIterator implements IRunIterator { private final IMessage.Kind failureKind; - private boolean didCleanup; +// private boolean didCleanup; /** * Create a RunSpecIterator. diff --git a/testing/src/org/aspectj/testing/harness/bridge/Validator.java b/testing/src/org/aspectj/testing/harness/bridge/Validator.java index e5f544356..24a58bf5f 100644 --- a/testing/src/org/aspectj/testing/harness/bridge/Validator.java +++ b/testing/src/org/aspectj/testing/harness/bridge/Validator.java @@ -487,7 +487,7 @@ public class Validator { fail(failMessage + ": unable to get parent " + dir); } } else { - File result = FileUtil.makeNewChildDir(dir, name); + FileUtil.makeNewChildDir(dir, name); if (deleteContents) { FileUtil.deleteContents(dir); } diff --git a/testing/src/org/aspectj/testing/run/Runner.java b/testing/src/org/aspectj/testing/run/Runner.java index 2ea278e72..9e84dee7f 100644 --- a/testing/src/org/aspectj/testing/run/Runner.java +++ b/testing/src/org/aspectj/testing/run/Runner.java @@ -63,8 +63,8 @@ public class Runner { private static final IMessage FAIL_NORUN = MessageUtil.fail("Null IRun parameter to Runner.run(IRun..)"); - private static final IMessage FAIL_NORUN_ITERATOR - = MessageUtil.fail("Null IRunterator parameter to Runner.run(IRunterator...)"); +// private static final IMessage FAIL_NORUN_ITERATOR +// = MessageUtil.fail("Null IRunterator parameter to Runner.run(IRunterator...)"); public Runner() { } diff --git a/testing/src/org/aspectj/testing/taskdefs/AjcTaskCompileCommand.java b/testing/src/org/aspectj/testing/taskdefs/AjcTaskCompileCommand.java index 9a8e9ab60..7a9864539 100644 --- a/testing/src/org/aspectj/testing/taskdefs/AjcTaskCompileCommand.java +++ b/testing/src/org/aspectj/testing/taskdefs/AjcTaskCompileCommand.java @@ -12,11 +12,11 @@ package org.aspectj.testing.taskdefs; -import java.awt.Frame; +//import java.awt.Frame; import java.io.*; -import java.lang.reflect.*; +//import java.lang.reflect.*; import java.util.*; -import java.util.List; +//import java.util.List; import org.apache.tools.ant.*; import org.apache.tools.ant.Project; @@ -71,7 +71,7 @@ public class AjcTaskCompileCommand implements ICommand { } long curTime = System.currentTimeMillis(); final long timeout = curTime + (timeoutSeconds*1000); - final Thread thread = Thread.currentThread(); +// final Thread thread = Thread.currentThread(); final long targetQuietTime = 1000 * seconds; int numMessages = holder.numMessages(null, true); long numMessagesTime = curTime; diff --git a/testing/src/org/aspectj/testing/util/BridgeUtil.java b/testing/src/org/aspectj/testing/util/BridgeUtil.java index 10117c398..72bec102f 100644 --- a/testing/src/org/aspectj/testing/util/BridgeUtil.java +++ b/testing/src/org/aspectj/testing/util/BridgeUtil.java @@ -31,7 +31,7 @@ import org.aspectj.util.LineReader; */ public class BridgeUtil { - private static final String INDENT = " "; +// private static final String INDENT = " "; /** result value when writeMessage is passed null */ private static final String NULL_MESSAGE_OUTPUT = ""; @@ -298,7 +298,7 @@ public class BridgeUtil { * file:#:# - file, line, column * file:#:#:? - file, line, column, message */ - SourceLocation result = null; +// SourceLocation result = null; if ((null == input) || (0 == input.length())) { if (null == defaultFile) { return null; @@ -312,7 +312,7 @@ public class BridgeUtil { int line = 0; int endLine = 0; int column = 0; - String message = null; +// String message = null; // first try line only line = convert(input); @@ -355,7 +355,7 @@ public class BridgeUtil { //col = "expecting col(number) at \"" + col + "\" in " + input; //throw new IllegalArgumentException(col); } else if (-1 != colon3) { // 3 colon => message - message = input.substring(colon3+1); // do not trim message + input.substring(colon3+1); // do not trim message } } } diff --git a/testing/src/org/aspectj/testing/util/LangUtil.java b/testing/src/org/aspectj/testing/util/LangUtil.java index c6b4b9ae1..d25012eac 100644 --- a/testing/src/org/aspectj/testing/util/LangUtil.java +++ b/testing/src/org/aspectj/testing/util/LangUtil.java @@ -244,7 +244,7 @@ public class LangUtil { } StringBuffer result = new StringBuffer(); final String cname = LangUtil.unqualifiedClassName(superType); - int index = 0; +// int index = 0; for (int i = 0; i < ra.length; i++) { if (null == ra[i]) { result.append(", [" + i + "] null"); @@ -354,8 +354,8 @@ public class LangUtil { String emptyUnflattened) { throwIaxIfNull(input, "input"); final boolean haveDelim = (!isEmpty(delim)); - final boolean haveNullFlattened = (null != nullFlattened); - final boolean escaping = (haveDelim && (null != escape)); +// final boolean haveNullFlattened = (null != nullFlattened); +// final boolean escaping = (haveDelim && (null != escape)); if (!isEmpty(prefix)) { if (input.startsWith(prefix)) { input = input.substring(prefix.length()); @@ -383,9 +383,9 @@ public class LangUtil { } StringTokenizer st = new StringTokenizer(input, delim, true); - StringBuffer cur = new StringBuffer(); - boolean lastEndedWithEscape = false; - boolean lastWasDelim = false; +// StringBuffer cur = new StringBuffer(); +// boolean lastEndedWithEscape = false; +// boolean lastWasDelim = false; while (st.hasMoreTokens()) { String token = st.nextToken(); System.out.println("reading " + token); diff --git a/testing/src/org/aspectj/testing/util/LinkCheck.java b/testing/src/org/aspectj/testing/util/LinkCheck.java index ef85cbf53..943884b39 100644 --- a/testing/src/org/aspectj/testing/util/LinkCheck.java +++ b/testing/src/org/aspectj/testing/util/LinkCheck.java @@ -23,7 +23,7 @@ import javax.swing.text.html.HTML.Tag; import org.aspectj.bridge.*; import org.aspectj.bridge.IMessageHandler; import org.aspectj.util.LangUtil; -import org.aspectj.util.FileUtil; +//import org.aspectj.util.FileUtil; /** * Quick and dirty link checker. @@ -146,14 +146,14 @@ public class LinkCheck { } } - private static boolean isCheckedFileType(URL url) { - if (null == url) { - return false; - } - String file = url.getFile(); - return !FileUtil.hasZipSuffix(file) - && !file.endsWith(".pdf"); - } +// private static boolean isCheckedFileType(URL url) { +// if (null == url) { +// return false; +// } +// String file = url.getFile(); +// return !FileUtil.hasZipSuffix(file) +// && !file.endsWith(".pdf"); +// } private final Messages messages; private final HTMLEditorKit.Parser parser; // XXX untested - stateful @@ -353,13 +353,13 @@ public class LinkCheck { info("uncommentedReference", link); // XXX bug? } - private void addingNullLinkFrom(URL doc) { - info("addingNullLinkFrom", doc); - } - - private void noContentCheck(Link link) { - info("noContentCheck", link); - } +// private void addingNullLinkFrom(URL doc) { +// info("addingNullLinkFrom", doc); +// } +// +// private void noContentCheck(Link link) { +// info("noContentCheck", link); +// } private void notTextContentType(Link link) { info("notTextContentType", link); @@ -381,9 +381,9 @@ public class LinkCheck { info("acceptingUncheckedLink", "doc=" + doc + " link=" + link); } - private void cantHandleRefsYet(Link link) { - info("cantHandleRefsYet", link.url); - } +// private void cantHandleRefsYet(Link link) { +// info("cantHandleRefsYet", link.url); +// } private void namedReferenceNotFound(String ref) { // XXX find all references to this unfound named reference diff --git a/testing/src/org/aspectj/testing/util/RunUtils.java b/testing/src/org/aspectj/testing/util/RunUtils.java index cedc72c84..0be8e0e91 100644 --- a/testing/src/org/aspectj/testing/util/RunUtils.java +++ b/testing/src/org/aspectj/testing/util/RunUtils.java @@ -65,7 +65,7 @@ public class RunUtils { return 1; } } else { - int i = 0; +// int i = 0; for (int j = 0; j < children.length; j++) { if (recurse) { numFails += numFailures(children[j], recurse); diff --git a/testing/src/org/aspectj/testing/util/StreamsHandler.java b/testing/src/org/aspectj/testing/util/StreamsHandler.java index bd550ada7..257ab7ea4 100644 --- a/testing/src/org/aspectj/testing/util/StreamsHandler.java +++ b/testing/src/org/aspectj/testing/util/StreamsHandler.java @@ -90,7 +90,7 @@ public class StreamsHandler { outDelegate = new ProxyPrintStream(System.out); errDelegate = new ProxyPrintStream(System.err); this.listening = listen; - final PrintStream HIDE = NullPrintStream.NULL_PrintStream; +// final PrintStream HIDE = NullPrintStream.NULL_PrintStream; outSniffer = new StreamSniffer(outDelegate); System.setOut(new PrintStream(outSniffer)); errSniffer = new StreamSniffer(errDelegate); diff --git a/testing/src/org/aspectj/testing/util/TestDiffs.java b/testing/src/org/aspectj/testing/util/TestDiffs.java index 2a69b1634..adba2d69b 100644 --- a/testing/src/org/aspectj/testing/util/TestDiffs.java +++ b/testing/src/org/aspectj/testing/util/TestDiffs.java @@ -121,7 +121,7 @@ public class TestDiffs { // XXX pretty dumb implementation if ((null == out) || LangUtil.isEmpty(list)) { return; } - int i = 0; +// int i = 0; final String suffix = " " + label; final String LABEL = list.size() + suffix; out.println("## START " + LABEL); diff --git a/testing/src/org/aspectj/testing/util/options/Option.java b/testing/src/org/aspectj/testing/util/options/Option.java index 85917922e..b2f151ea4 100644 --- a/testing/src/org/aspectj/testing/util/options/Option.java +++ b/testing/src/org/aspectj/testing/util/options/Option.java @@ -478,9 +478,9 @@ public class Option implements Comparable { return Factory.class.getName() + ": " + factoryName; } - private void checkUnique(Option result) { - String name = result.family + "." + result.name; - } +// private void checkUnique(Option result) { +// String name = result.family + "." + result.name; +// } } /** diff --git a/testing/src/org/aspectj/testing/util/options/Options.java b/testing/src/org/aspectj/testing/util/options/Options.java index 642ea0ca7..e1682556f 100644 --- a/testing/src/org/aspectj/testing/util/options/Options.java +++ b/testing/src/org/aspectj/testing/util/options/Options.java @@ -25,7 +25,7 @@ import org.aspectj.util.LangUtil; public class Options { /** if true, then perform extra checks to debug problems */ - private static final boolean verifying = false; +// private static final boolean verifying = false; private static final boolean FROZEN = true; /** @@ -139,7 +139,7 @@ public class Options { private Option.Value firstMatch(String value) { LangUtil.throwIaxIfNull(value, "value"); - ArrayList list = new ArrayList(); +// ArrayList list = new ArrayList(); for (Iterator iter = options.iterator(); iter.hasNext();) { Option option = (Option) iter.next(); Option.Value result = option.acceptValue(value); diff --git a/testing/src/org/aspectj/testing/util/options/Values.java b/testing/src/org/aspectj/testing/util/options/Values.java index 21cd3b52f..0d85f0851 100644 --- a/testing/src/org/aspectj/testing/util/options/Values.java +++ b/testing/src/org/aspectj/testing/util/options/Values.java @@ -170,7 +170,7 @@ public class Values { private static String resolve(Option.Value[] input, int[] matches) { String err = null; // seek force-off - Option.Value forceOff = null; +// Option.Value forceOff = null; Option option = null; // find and remove any force-off for (int i = 0;(null == err) && (i < matches.length); i++) { diff --git a/testing/src/org/aspectj/testing/xml/AjcSpecXmlReader.java b/testing/src/org/aspectj/testing/xml/AjcSpecXmlReader.java index 60be24296..900e617a4 100644 --- a/testing/src/org/aspectj/testing/xml/AjcSpecXmlReader.java +++ b/testing/src/org/aspectj/testing/xml/AjcSpecXmlReader.java @@ -16,7 +16,7 @@ package org.aspectj.testing.xml; import java.io.*; -import java.util.Vector; +//import java.util.Vector; import org.apache.commons.digester.Digester; import org.aspectj.bridge.AbortException; @@ -61,7 +61,7 @@ public class AjcSpecXmlReader { * - property read-only (?) */ - private static final String EOL = "\n"; +// private static final String EOL = "\n"; /** presumed relative-path to dtd file for any XML files written by writeSuiteToXmlFile */ public static final String DTD_PATH = "../tests/ajcTestSuite.dtd"; @@ -318,63 +318,63 @@ public class AjcSpecXmlReader { * The property setter checks are redundant with tests based on * expectedProperties(). */ - private static void setupDigesterCompileTimeCheck() { - if (true) { throw new Error("never invoked"); } - AjcTest.Suite.Spec suite = new AjcTest.Suite.Spec(); - AjcTest.Spec test = new AjcTest.Spec(); -// AjcTest test = new AjcTest(); -// test.addRunSpec((AbstractRunSpec) null); -//// test.makeIncCompilerRun((IncCompilerRun.Spec) null); -//// test.makeJavaRun((JavaRun.Spec) null); -// test.setDescription((String) null); -// test.setTestBaseDirOffset((String) null); -// test.setBugId((String) null); -// test.setTestSourceLocation((ISourceLocation) null); - - CompilerRun.Spec crunSpec = new CompilerRun.Spec(); - crunSpec.addMessage((IMessage) null); - // XXX crunSpec.addSourceLocation((ISourceLocation) null); - crunSpec.addWrapFile((AbstractRunSpec.WrapFile) null); - crunSpec.setOptions((String) null); - crunSpec.setPaths((String) null); - crunSpec.setIncludeClassesDir(false); - crunSpec.setReuseCompiler(false); - - IncCompilerRun.Spec icrunSpec = new IncCompilerRun.Spec(); - icrunSpec.addMessage((IMessage) null); - icrunSpec.setTag((String) null); - icrunSpec.setFresh(false); - - JavaRun.Spec jrunspec = new JavaRun.Spec(); - jrunspec.addMessage((IMessage) null); - jrunspec.setClassName((String) null); - jrunspec.addMessage((IMessage) null); - // input s.b. interpretable by Boolean.valueOf(String) - jrunspec.setSkipTester(true); - jrunspec.setErrStreamIsError(true); - jrunspec.setOutStreamIsError(true); - - DirChanges.Spec dcspec = new DirChanges.Spec(); - dcspec.setAdded((String) null); - dcspec.setRemoved((String) null); - dcspec.setUpdated((String) null); - dcspec.setDefaultSuffix((String) null); - dcspec.setDirToken((String) null); - - SoftMessage m = new SoftMessage(); - m.setSourceLocation((ISourceLocation) null); - m.setText((String) null); - m.setKindAsString((String) null); - m.setDetails((String) null); - - SoftSourceLocation sl = new SoftSourceLocation(); - sl.setFile((String) null); - sl.setLine((String) null); - sl.setColumn((String) null); - sl.setEndLine((String) null); - - // add attribute setters to validate? - } +// private static void setupDigesterCompileTimeCheck() { +// if (true) { throw new Error("never invoked"); } +// AjcTest.Suite.Spec suite = new AjcTest.Suite.Spec(); +// AjcTest.Spec test = new AjcTest.Spec(); +//// AjcTest test = new AjcTest(); +//// test.addRunSpec((AbstractRunSpec) null); +////// test.makeIncCompilerRun((IncCompilerRun.Spec) null); +////// test.makeJavaRun((JavaRun.Spec) null); +//// test.setDescription((String) null); +//// test.setTestBaseDirOffset((String) null); +//// test.setBugId((String) null); +//// test.setTestSourceLocation((ISourceLocation) null); +// +// CompilerRun.Spec crunSpec = new CompilerRun.Spec(); +// crunSpec.addMessage((IMessage) null); +// // XXX crunSpec.addSourceLocation((ISourceLocation) null); +// crunSpec.addWrapFile((AbstractRunSpec.WrapFile) null); +// crunSpec.setOptions((String) null); +// crunSpec.setPaths((String) null); +// crunSpec.setIncludeClassesDir(false); +// crunSpec.setReuseCompiler(false); +// +// IncCompilerRun.Spec icrunSpec = new IncCompilerRun.Spec(); +// icrunSpec.addMessage((IMessage) null); +// icrunSpec.setTag((String) null); +// icrunSpec.setFresh(false); +// +// JavaRun.Spec jrunspec = new JavaRun.Spec(); +// jrunspec.addMessage((IMessage) null); +// jrunspec.setClassName((String) null); +// jrunspec.addMessage((IMessage) null); +// // input s.b. interpretable by Boolean.valueOf(String) +// jrunspec.setSkipTester(true); +// jrunspec.setErrStreamIsError(true); +// jrunspec.setOutStreamIsError(true); +// +// DirChanges.Spec dcspec = new DirChanges.Spec(); +// dcspec.setAdded((String) null); +// dcspec.setRemoved((String) null); +// dcspec.setUpdated((String) null); +// dcspec.setDefaultSuffix((String) null); +// dcspec.setDirToken((String) null); +// +// SoftMessage m = new SoftMessage(); +// m.setSourceLocation((ISourceLocation) null); +// m.setText((String) null); +// m.setKindAsString((String) null); +// m.setDetails((String) null); +// +// SoftSourceLocation sl = new SoftSourceLocation(); +// sl.setFile((String) null); +// sl.setLine((String) null); +// sl.setColumn((String) null); +// sl.setEndLine((String) null); +// +// // add attribute setters to validate? +// } /** top element on Digester stack holds the test suite */ public static class SuiteHolder { diff --git a/testing/src/org/aspectj/testing/xml/MessageListXmlReader.java b/testing/src/org/aspectj/testing/xml/MessageListXmlReader.java index bd909ed3f..161bd541a 100644 --- a/testing/src/org/aspectj/testing/xml/MessageListXmlReader.java +++ b/testing/src/org/aspectj/testing/xml/MessageListXmlReader.java @@ -166,27 +166,27 @@ public class MessageListXmlReader { * The property setter checks are redundant with tests based on * expectedProperties(). */ - private static void setupDigesterCompileTimeCheck() { - if (true) { throw new Error("never invoked"); } - - MessageListHolder holder = new MessageListHolder(); - MessageList ml = new MessageList(); - SoftMessage m = new SoftMessage(); - SoftSourceLocation sl = new SoftSourceLocation(); - - holder.setMessageList(ml); - ml.addMessage((IMessage) null); - m.setSourceLocation(sl); - m.setText((String) null); - m.setKindAsString((String) null); - - sl.setFile((String) null); - sl.setLine((String) null); - sl.setColumn((String) null); - sl.setEndLine((String) null); - - // add attribute setters to validate? - } +// private static void setupDigesterCompileTimeCheck() { +// if (true) { throw new Error("never invoked"); } +// +// MessageListHolder holder = new MessageListHolder(); +// MessageList ml = new MessageList(); +// SoftMessage m = new SoftMessage(); +// SoftSourceLocation sl = new SoftSourceLocation(); +// +// holder.setMessageList(ml); +// ml.addMessage((IMessage) null); +// m.setSourceLocation(sl); +// m.setText((String) null); +// m.setKindAsString((String) null); +// +// sl.setFile((String) null); +// sl.setLine((String) null); +// sl.setColumn((String) null); +// sl.setEndLine((String) null); +// +// // add attribute setters to validate? +// } // inner classes, to make public for bean utilities /** a list of messages */ diff --git a/testing/src/org/aspectj/testing/xml/SoftMessage.java b/testing/src/org/aspectj/testing/xml/SoftMessage.java index 8caa77828..9c8ca57e1 100644 --- a/testing/src/org/aspectj/testing/xml/SoftMessage.java +++ b/testing/src/org/aspectj/testing/xml/SoftMessage.java @@ -15,7 +15,7 @@ package org.aspectj.testing.xml; import java.io.File; import java.util.ArrayList; -import java.util.Collections; +//import java.util.Collections; import java.util.Iterator; import java.util.List; @@ -124,7 +124,7 @@ public class SoftMessage implements IMessage { if (!LangUtil.isEmpty(extras)) { out.endAttributes(); for (Iterator iter = extras.iterator(); iter.hasNext();) { - ISourceLocation element = (ISourceLocation) iter.next(); + /*ISourceLocation element = (ISourceLocation)*/ iter.next(); SoftSourceLocation.writeXml(out, sl); } } diff --git a/testing/src/org/aspectj/testing/xml/XMLWriter.java b/testing/src/org/aspectj/testing/xml/XMLWriter.java index fd7bbf19f..9c0ca20f3 100644 --- a/testing/src/org/aspectj/testing/xml/XMLWriter.java +++ b/testing/src/org/aspectj/testing/xml/XMLWriter.java @@ -261,7 +261,7 @@ public class XMLWriter { * @throws IllegalStateException if start element does not match */ public void endElement(String name) { - int level = stack.size(); +// int level = stack.size(); String err = null; StackElement element = null; if (0 == stack.size()) { diff --git a/testing/testsrc/org/aspectj/testing/harness/bridge/AjcSpecTest.java b/testing/testsrc/org/aspectj/testing/harness/bridge/AjcSpecTest.java index eaca921ed..f48000d18 100644 --- a/testing/testsrc/org/aspectj/testing/harness/bridge/AjcSpecTest.java +++ b/testing/testsrc/org/aspectj/testing/harness/bridge/AjcSpecTest.java @@ -193,7 +193,7 @@ public class AjcSpecTest extends TestCase { // } public static void sameIAjcRun(IAjcRun lhs, IAjcRun rhs, Assert reporter) { - Assert a = reporter; +// Assert a = reporter; assertTrue(lhs != null); assertTrue(rhs != null); Class c = lhs.getClass(); diff --git a/testing/testsrc/org/aspectj/testing/harness/bridge/CompilerRunSpecTest.java b/testing/testsrc/org/aspectj/testing/harness/bridge/CompilerRunSpecTest.java index d418755ae..8bc83ca98 100644 --- a/testing/testsrc/org/aspectj/testing/harness/bridge/CompilerRunSpecTest.java +++ b/testing/testsrc/org/aspectj/testing/harness/bridge/CompilerRunSpecTest.java @@ -240,7 +240,7 @@ public class CompilerRunSpecTest extends TestCase { assertTrue(spec != null); AbstractRunSpec.RT parentRuntime = new AbstractRunSpec.RT(); String result; - String expResult; +// String expResult; if (null != arg) { parentRuntime.setOptions(new String[] { arg }); @@ -342,7 +342,7 @@ public class CompilerRunSpecTest extends TestCase { String resultContains = !expectPass ? null : "[-" + name + ", 1." + i; String messagesContain = expectedErr; - MessageHandler handler = + /*MessageHandler handler =*/ runTest( specOptions, globalOptions, diff --git a/testing/testsrc/org/aspectj/testing/harness/bridge/CompilerRunTest.java b/testing/testsrc/org/aspectj/testing/harness/bridge/CompilerRunTest.java index 002bd5e4f..af0a22b0a 100644 --- a/testing/testsrc/org/aspectj/testing/harness/bridge/CompilerRunTest.java +++ b/testing/testsrc/org/aspectj/testing/harness/bridge/CompilerRunTest.java @@ -35,9 +35,9 @@ public class CompilerRunTest extends TestCase { dummyReports.add("run: " + Arrays.asList(args)); } - private static void dummyRepeating(String[] args) { - dummyReports.add("repeat: " + Arrays.asList(args)); - } +// private static void dummyRepeating(String[] args) { +// dummyReports.add("repeat: " + Arrays.asList(args)); +// } private File testBaseDir; @@ -67,7 +67,7 @@ public class CompilerRunTest extends TestCase { } public void testExtDirs() { - String[] globals = null; +// String[] globals = null; CompilerRun.Spec spec = new CompilerRun.Spec(); spec.setExtdirs("one,two"); spec.setFiles("Foo.java"); diff --git a/testing/testsrc/org/aspectj/testing/harness/bridge/ParseTestCase.java b/testing/testsrc/org/aspectj/testing/harness/bridge/ParseTestCase.java index ee7720a68..bb5a58c58 100644 --- a/testing/testsrc/org/aspectj/testing/harness/bridge/ParseTestCase.java +++ b/testing/testsrc/org/aspectj/testing/harness/bridge/ParseTestCase.java @@ -112,7 +112,7 @@ public class ParseTestCase extends TestCase { System.out.println(test); - List ret = new ArrayList(); +// List ret = new ArrayList(); NodeList children = node.getChildNodes(); for (int i=0; i < children.getLength(); i++) { @@ -127,7 +127,7 @@ public class ParseTestCase extends TestCase { String kind = node.getNodeName(); if (kind.equals("compile")) { List args = parseChildrenStrings(node, "arg"); - List files = parseChildrenStrings(node, "file"); + /*List files = */parseChildrenStrings(node, "file"); List expectedMessages = parseChildrenMessages(node); CompilerRun.Spec spec = new CompilerRun.Spec(); spec.addOptions((String[]) args.toArray(new String[0])); @@ -139,7 +139,7 @@ public class ParseTestCase extends TestCase { JavaRun.Spec spec = new JavaRun.Spec(); spec.className = getAttributeString(node, "class"); spec.addOptions(new String[0]); //??? could add support here - JavaRun run = new JavaRun(spec); + /*JavaRun run = */new JavaRun(spec); return spec; } diff --git a/testing/testsrc/org/aspectj/testing/taskdefs/AjcTaskCompileCommandTest.java b/testing/testsrc/org/aspectj/testing/taskdefs/AjcTaskCompileCommandTest.java index 9f5d93bd2..c8ec8e1b4 100644 --- a/testing/testsrc/org/aspectj/testing/taskdefs/AjcTaskCompileCommandTest.java +++ b/testing/testsrc/org/aspectj/testing/taskdefs/AjcTaskCompileCommandTest.java @@ -231,7 +231,7 @@ class MessageAdder implements Runnable { final long waitBetweenAdds = interval * 1000l; long curTime = System.currentTimeMillis(); final long timeout = curTime + MAX_MILLIS; - final Thread thread = Thread.currentThread(); +// final Thread thread = Thread.currentThread(); int numAdded = 0; while (!stop && (timeout > curTime) && (numAdded < numToAdd)) { diff --git a/testing/testsrc/org/aspectj/testing/util/LangUtilTest.java b/testing/testsrc/org/aspectj/testing/util/LangUtilTest.java index ebdb21cc5..21e4b263d 100644 --- a/testing/testsrc/org/aspectj/testing/util/LangUtilTest.java +++ b/testing/testsrc/org/aspectj/testing/util/LangUtilTest.java @@ -70,7 +70,7 @@ public class LangUtilTest extends TestCase { public void skiptestUnflatten() { - LangUtil.FlattenSpec COMMA = LangUtil.FlattenSpec.COMMA; +// LangUtil.FlattenSpec COMMA = LangUtil.FlattenSpec.COMMA; LangUtil.FlattenSpec LIST = LangUtil.FlattenSpec.LIST; FTest[] tests = new FTest[] diff --git a/testing/testsrc/org/aspectj/testing/util/options/OptionChecker.java b/testing/testsrc/org/aspectj/testing/util/options/OptionChecker.java index 6792d556c..a7d65dd53 100644 --- a/testing/testsrc/org/aspectj/testing/util/options/OptionChecker.java +++ b/testing/testsrc/org/aspectj/testing/util/options/OptionChecker.java @@ -129,9 +129,9 @@ public class OptionChecker { options); } - private Values getValues(String[] input, Options options) { - return getValuesNegative(input, null, options); - } +// private Values getValues(String[] input, Options options) { +// return getValuesNegative(input, null, options); +// } private Values getValues(String[] input) { return getValuesNegative(input, null); diff --git a/testing/testsrc/org/aspectj/testing/util/options/OptionsTest.java b/testing/testsrc/org/aspectj/testing/util/options/OptionsTest.java index 29048aa07..40b197996 100644 --- a/testing/testsrc/org/aspectj/testing/util/options/OptionsTest.java +++ b/testing/testsrc/org/aspectj/testing/util/options/OptionsTest.java @@ -105,7 +105,7 @@ public class OptionsTest extends TestCase { return OPTIONS; } - private boolean verbose; +// private boolean verbose; private OptionChecker localOptionChecker; public void testDebugCase() { diff --git a/testing/testsrc/org/aspectj/testing/xml/AjcSpecXmlReaderTest.java b/testing/testsrc/org/aspectj/testing/xml/AjcSpecXmlReaderTest.java index a945652b9..c00ceb9ea 100644 --- a/testing/testsrc/org/aspectj/testing/xml/AjcSpecXmlReaderTest.java +++ b/testing/testsrc/org/aspectj/testing/xml/AjcSpecXmlReaderTest.java @@ -22,7 +22,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.Iterator; -import junit.framework.*; +//import junit.framework.*; import junit.framework.TestCase; import org.aspectj.testing.harness.bridge.AjcSpecTest; @@ -62,7 +62,7 @@ public class AjcSpecXmlReaderTest extends TestCase { /** test that all AjcSpecXmlReader.me.expectedProperties() are bean-writable */ public void testBeanInfo() throws IntrospectionException { - AjcSpecXmlReader me = AjcSpecXmlReader.getReader(); +// AjcSpecXmlReader me = AjcSpecXmlReader.getReader(); AjcSpecXmlReader.BProps[] expected = AjcSpecXmlReader.expectedProperties(); PropertyDescriptor[] des; -- 2.39.5