From 77c6ad9f84b6601cd05c7ed01fb2402497cddfbc Mon Sep 17 00:00:00 2001 From: wisberg Date: Wed, 30 Apr 2003 02:41:39 +0000 Subject: [PATCH] no change, just nicer feedback --- ajde/testsrc/org/aspectj/ajde/CompilerMessagesTest.java | 5 +++++ ajde/testsrc/org/aspectj/ajde/StructureModelTest.java | 7 +++++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/ajde/testsrc/org/aspectj/ajde/CompilerMessagesTest.java b/ajde/testsrc/org/aspectj/ajde/CompilerMessagesTest.java index ce3361cca..92174397a 100644 --- a/ajde/testsrc/org/aspectj/ajde/CompilerMessagesTest.java +++ b/ajde/testsrc/org/aspectj/ajde/CompilerMessagesTest.java @@ -12,6 +12,8 @@ package org.aspectj.ajde; +import org.aspectj.bridge.MessageUtil; + import java.io.IOException; import java.util.List; @@ -38,6 +40,9 @@ public class CompilerMessagesTest extends AjdeTestCase { // The build has happened, what messages did the compiler give, and do they // contain the information we expect? List msgs = NullIdeManager.getIdeManager().getCompilationSourceLineTasks(); + if (1 != msgs.size()) { + assertTrue("not one message: " + msgs, false); + } assertEquals("One warning message should be produced",1,msgs.size()); NullIdeTaskListManager.SourceLineTask task = (NullIdeTaskListManager.SourceLineTask) msgs.get(0); diff --git a/ajde/testsrc/org/aspectj/ajde/StructureModelTest.java b/ajde/testsrc/org/aspectj/ajde/StructureModelTest.java index 1c5fb1e61..625990e3a 100644 --- a/ajde/testsrc/org/aspectj/ajde/StructureModelTest.java +++ b/ajde/testsrc/org/aspectj/ajde/StructureModelTest.java @@ -84,7 +84,8 @@ public class StructureModelTest extends AjdeTestCase { testFile.getCanonicalPath()); assertTrue("find result", node != null) ; ProgramElementNode pNode = (ProgramElementNode)node; - assertTrue("found child", ((StructureNode)pNode.getChildren().get(0)).getName().equals("Figure")); + String child = ((StructureNode)pNode.getChildren().get(0)).getName(); + assertTrue("expected Figure got child " + child, child.equals("Figure")); } public void testPointcutName() throws IOException { @@ -120,7 +121,9 @@ public class StructureModelTest extends AjdeTestCase { assertTrue("find result", node != null); ProgramElementNode pNode = (ProgramElementNode)((ProgramElementNode)node).getParent(); - assertTrue("null parent", pNode != null); + if (null == pNode) { + assertTrue("null parent of " + node, false); + } assertTrue("found node: " + pNode.getName(), pNode.isRunnable()); } -- 2.39.5